Skip to content

Commit 44cd777

Browse files
author
Pavel Kosov
committed
[LNT] Removed 0x checking for offsets in profile assembly
This logic has been added in D110141. It seems some objdump implementations do not produce 0x before hex offsets. Assume all regular offsets are hex as before, but relative offsets started with # are dec. Reviewed By: cmatthews Differential Revision: https://reviews.llvm.org/D120539
1 parent f984afe commit 44cd777

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

lnt/server/ui/static/lnt_profile.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -139,7 +139,7 @@ CFG.prototype = {
139139
// and should be processed differently
140140
var isRelative = addressString.startsWith('#');
141141
var charOffset = (isRelative ? 1 : 0);
142-
var base = (addressString.substring(charOffset).startsWith('0x') ? 16 : 10);
142+
var base = (isRelative ? 10 : 16);
143143
if (isRelative)
144144
return addressCurrent + parseInt(addressString.substring(1), base);
145145
else

0 commit comments

Comments
 (0)