Changeset 249052 in webkit
- Timestamp:
- Aug 23, 2019 10:21:19 AM (5 years ago)
- Location:
- trunk/Source/JavaScriptCore
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/Source/JavaScriptCore/ChangeLog
r249036 r249052 1 2019-08-22 Mark Lam <mark.lam@apple.com> 2 3 VirtualRegister::dump() can use more informative CallFrame header slot names. 4 https://bugs.webkit.org/show_bug.cgi?id=201062 5 6 Reviewed by Tadeu Zagallo. 7 8 For example, it currently dumps head3 instead of callee. This patch changes the 9 dump as follows (for 64-bit addressing): 10 head0 => callerFrame 11 head1 => returnPC 12 head2 => codeBlock 13 head3 => callee 14 head4 => argumentCount 15 16 Now, one might be wondering when would bytecode ever access callerFrame and 17 returnPC? The answer is never. However, I don't think its the role of the 18 dumper to catch a bug where these header slots are being used. The dumper's role 19 is to clearly report them so that we can see that these unexpected values are 20 being used. 21 22 * bytecode/VirtualRegister.cpp: 23 (JSC::VirtualRegister::dump const): 24 1 25 2019-08-22 Andy Estes <aestes@apple.com> 2 26 -
trunk/Source/JavaScriptCore/bytecode/VirtualRegister.cpp
r237547 r249052 1 1 /* 2 * Copyright (C) 2011 , 2015Apple Inc. All rights reserved.2 * Copyright (C) 2011-2019 Apple Inc. All rights reserved. 3 3 * 4 4 * Redistribution and use in source and binary forms, with or without … … 39 39 40 40 if (isHeader()) { 41 out.print("head", m_virtualRegister); 41 if (m_virtualRegister == CallFrameSlot::codeBlock) 42 out.print("codeBlock"); 43 else if (m_virtualRegister == CallFrameSlot::callee) 44 out.print("callee"); 45 else if (m_virtualRegister == CallFrameSlot::argumentCount) 46 out.print("argumentCount"); 47 #if CPU(ADDRESS64) 48 else if (!m_virtualRegister) 49 out.print("callerFrame"); 50 else if (m_virtualRegister == 1) 51 out.print("returnPC"); 52 #else 53 else if (!m_virtualRegister) 54 out.print("callerFrameAndReturnPC"); 55 #endif 42 56 return; 43 57 }
Note: See TracChangeset
for help on using the changeset viewer.