Skip to content

Commit 2a5fd80

Browse files
committed
[BOLT] Improve warnings in MarkRAStates
- Previously, the same warning was printed in 3 different cases. Changed warnings to be more specific.
1 parent 0bfae2c commit 2a5fd80

File tree

1 file changed

+6
-0
lines changed

1 file changed

+6
-0
lines changed

bolt/lib/Passes/MarkRAStates.cpp

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -57,6 +57,8 @@ void MarkRAStates::runOnFunction(BinaryFunction &BF) {
5757
BF.setIgnored();
5858
BC.outs() << "BOLT-INFO: inconsistent RAStates in function "
5959
<< BF.getPrintName() << "\n";
60+
BC.outs()
61+
<< "BOLT-INFO: ptr sign/auth inst without .cfi_negate_ra_state\n";
6062
return;
6163
}
6264
}
@@ -78,6 +80,8 @@ void MarkRAStates::runOnFunction(BinaryFunction &BF) {
7880
// RA signing instructions should only follow unsigned RA state.
7981
BC.outs() << "BOLT-INFO: inconsistent RAStates in function "
8082
<< BF.getPrintName() << "\n";
83+
BC.outs() << "BOLT-INFO: ptr signing inst encountered in Signed RA "
84+
"state.\n";
8185
BF.setIgnored();
8286
return;
8387
}
@@ -87,6 +91,8 @@ void MarkRAStates::runOnFunction(BinaryFunction &BF) {
8791
// RA authenticating instructions should only follow signed RA state.
8892
BC.outs() << "BOLT-INFO: inconsistent RAStates in function "
8993
<< BF.getPrintName() << "\n";
94+
BC.outs() << "BOLT-INFO: ptr authenticating inst encountered in "
95+
"Unsigned RA state.\n";
9096
BF.setIgnored();
9197
return;
9298
}

0 commit comments

Comments
 (0)