Skip to content

[DWARFVerifier] Fix and enable broken test llvm-dwarfdump/X86/verify_no_overlap_error_icf.yaml #120330

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 2 commits into from
Dec 19, 2024

Conversation

alx32
Copy link
Contributor

@alx32 alx32 commented Dec 17, 2024

Fixing broken test - calling sed in a cross-platform compatible way.
Verified to pass on Mac (which uses BSD sed).

@alx32 alx32 marked this pull request as ready for review December 17, 2024 23:18
@llvmbot
Copy link
Member

llvmbot commented Dec 17, 2024

@llvm/pr-subscribers-debuginfo

Author: None (alx32)

Changes

Fixing broken test - calling sed in a platform cross-compatible way.
Verified to pass on Mac (which uses BSD sed).


Full diff: https://github.com/llvm/llvm-project/pull/120330.diff

1 Files Affected:

  • (modified) llvm/test/tools/llvm-dwarfdump/X86/verify_no_overlap_error_icf.yaml (+3-7)
diff --git a/llvm/test/tools/llvm-dwarfdump/X86/verify_no_overlap_error_icf.yaml b/llvm/test/tools/llvm-dwarfdump/X86/verify_no_overlap_error_icf.yaml
index 43652831bdb2d2..5312e54e756a2f 100644
--- a/llvm/test/tools/llvm-dwarfdump/X86/verify_no_overlap_error_icf.yaml
+++ b/llvm/test/tools/llvm-dwarfdump/X86/verify_no_overlap_error_icf.yaml
@@ -1,7 +1,3 @@
-# FIXME: Currently disabled as it fails on some Mac hosts
-# https://github.com/llvm/llvm-project/pull/117952
-# UNSUPPORTED: true
-
 #--- comments.txt
 
 # This test verifies several scenarios with DW_TAG_subprogram address ranges:
@@ -22,13 +18,13 @@
 # RUN: yaml2obj %t/test.yaml | llvm-dwarfdump --error-display=details --verify - | FileCheck %s
 # CHECK: No errors.
 
-# RUN: sed '0,/HighOffset: 0x6000/{s//HighOffset: 0x5999/}' %t/test.yaml | yaml2obj | not llvm-dwarfdump --error-display=details --verify - | FileCheck %s --check-prefix=CHECK-RANGES
+# RUN: sed -e '1,/HighOffset: 0x6000/s/HighOffset: 0x6000/HighOffset: 0x5999/' %t/test.yaml | yaml2obj | not llvm-dwarfdump --error-display=details --verify - | FileCheck %s --check-prefix=CHECK-RANGES
 # CHECK-RANGES: error: DIEs have overlapping address ranges
 
-# RUN: sed '0,/Value:  0x77/{s/Value:  0x77/Value:  0x66/}' %t/test.yaml | yaml2obj | not llvm-dwarfdump --error-display=details --verify - | FileCheck %s --check-prefix=CHECK-HIGH-PC
+# RUN: sed -e '1,/Value:  0x77/s/Value:  0x77/Value:  0x66/' %t/test.yaml | yaml2obj | not llvm-dwarfdump --error-display=details --verify - | FileCheck %s --check-prefix=CHECK-HIGH-PC
 # CHECK-HIGH-PC: error: DIEs have overlapping address ranges
 
-# RUN: sed '0,/LowOffset:  0x880111/{s//LowOffset:  0x880112/}' %t/test.yaml | yaml2obj | not llvm-dwarfdump --error-display=details --verify - | FileCheck %s --check-prefix=CHECK-LEX-BLOCK
+# RUN: sed -e '1,/LowOffset:  0x880111/s/LowOffset:  0x880111/LowOffset:  0x880112/' %t/test.yaml | yaml2obj | not llvm-dwarfdump --error-display=details --verify - | FileCheck %s --check-prefix=CHECK-LEX-BLOCK
 # CHECK-LEX-BLOCK: DIE has overlapping ranges in DW_AT_ranges attribute
 
 #--- test.yaml

@alx32 alx32 merged commit 1808255 into llvm:main Dec 19, 2024
5 of 7 checks passed
JDevlieghere pushed a commit to swiftlang/llvm-project that referenced this pull request Feb 4, 2025
…no_overlap_error_icf.yaml (llvm#120330)

Fixing broken test - calling `sed` in a cross-platform compatible way.
Verified to pass on Mac (which uses BSD sed).

(cherry picked from commit 1808255)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants