Skip to content

Commit

Permalink
IR: print value numbers for unnamed function arguments
Browse files Browse the repository at this point in the history
For consistency with normal instructions and clarity when reading IR,
it's best to print the %0, %1, ... names of function arguments in
definitions.

Also modifies the parser to accept IR in that form for obvious reasons.

llvm-svn: 367755
  • Loading branch information
TNorthover committed Aug 3, 2019
1 parent 6bf8612 commit a009a60
Show file tree
Hide file tree
Showing 184 changed files with 1,258 additions and 1,122 deletions.
4 changes: 2 additions & 2 deletions clang/test/CXX/except/except.spec/p14-ir.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -26,12 +26,12 @@ struct X4 {
struct X5 : X0, X4 { };

void test(X2 x2, X3 x3, X5 x5) {
// CHECK: define linkonce_odr void @_ZN2X2C1ERKS_(%struct.X2* %this, %struct.X2* dereferenceable({{[0-9]+}})) unnamed_addr
// CHECK: define linkonce_odr void @_ZN2X2C1ERKS_(%struct.X2* %this, %struct.X2* dereferenceable({{[0-9]+}}) %0) unnamed_addr
// CHECK: call void @_ZN2X2C2ERKS_({{.*}}) [[NUW:#[0-9]+]]
// CHECK-NEXT: ret void
// CHECK-NEXT: }
X2 x2a(x2);
// CHECK: define linkonce_odr void @_ZN2X3C1ERKS_(%struct.X3* %this, %struct.X3* dereferenceable({{[0-9]+}})) unnamed_addr
// CHECK: define linkonce_odr void @_ZN2X3C1ERKS_(%struct.X3* %this, %struct.X3* dereferenceable({{[0-9]+}}) %0) unnamed_addr
// CHECK: call void @_ZN2X3C2ERKS_({{.*}}) [[NUW]]
// CHECK-NEXT: ret void
// CHECK-NEXT: }
Expand Down
Loading

0 comments on commit a009a60

Please sign in to comment.