[llvm] 8fa570c - [WebAssembly] Fix incorrect DW_TAG_pointer_type size in test

Alex Richardson via llvm-commits llvm-commits at lists.llvm.org
Wed Mar 31 01:33:18 PDT 2021


Author: Alex Richardson
Date: 2021-03-31T09:17:45+01:00
New Revision: 8fa570c96908a459d3b067a815b7c307f4555556

URL: https://github.com/llvm/llvm-project/commit/8fa570c96908a459d3b067a815b7c307f4555556
DIFF: https://github.com/llvm/llvm-project/commit/8fa570c96908a459d3b067a815b7c307f4555556.diff

LOG: [WebAssembly] Fix incorrect DW_TAG_pointer_type size in test

It should be 64 bits not 32 for wasm64-unknown-unknown. I noticed this
because this test was failing in our CHERI fork of LLVM due to a larger
.debug_abbrev section size. It turns out this happens because we add
DW_AT_byte_size for non-default pointer sizes to allow debugging our
hybrid compilation mode where we can have two different kinds of pointers.

Reviewed By: aardappel

Differential Revision: https://reviews.llvm.org/D99410

Added: 
    

Modified: 
    llvm/test/MC/WebAssembly/debug-info64.ll

Removed: 
    


################################################################################
diff  --git a/llvm/test/MC/WebAssembly/debug-info64.ll b/llvm/test/MC/WebAssembly/debug-info64.ll
index acba8aa27360e..c35938ea767e5 100644
--- a/llvm/test/MC/WebAssembly/debug-info64.ll
+++ b/llvm/test/MC/WebAssembly/debug-info64.ll
@@ -275,10 +275,10 @@ attributes #0 = { noinline nounwind optnone "correctly-rounded-divide-sqrt-fp-ma
 !5 = !{!0, !6}
 !6 = !DIGlobalVariableExpression(var: !7, expr: !DIExpression())
 !7 = distinct !DIGlobalVariable(name: "ptr2", scope: !2, file: !3, line: 5, type: !8, isLocal: false, isDefinition: true)
-!8 = !DIDerivedType(tag: DW_TAG_pointer_type, baseType: !9, size: 32)
+!8 = !DIDerivedType(tag: DW_TAG_pointer_type, baseType: !9, size: 64)
 !9 = !DISubroutineType(types: !10)
 !10 = !{null}
-!11 = !DIDerivedType(tag: DW_TAG_pointer_type, baseType: !12, size: 32)
+!11 = !DIDerivedType(tag: DW_TAG_pointer_type, baseType: !12, size: 64)
 !12 = !DIBasicType(name: "int", size: 32, encoding: DW_ATE_signed)
 !13 = !{i32 2, !"Dwarf Version", i32 4}
 !14 = !{i32 2, !"Debug Info Version", i32 3}


        


More information about the llvm-commits mailing list