WebKit Bugzilla
New
Browse
Log In
×
Sign in with GitHub
or
Remember my login
Create Account
·
Forgot Password
Forgotten password account recovery
NEW
177372
Consider a throwExceptionIf bytecode.
https://bugs.webkit.org/show_bug.cgi?id=177372
Summary
Consider a throwExceptionIf bytecode.
Keith Miller
Reported
2017-09-22 11:35:44 PDT
There are several places in BytecodeGenerator.cpp where we emit roughly the following bytecodes: Ref<Label> typeIsObject = newLabel(); emitJumpIfTrue(emitIsObject(newTemporary(), dst), typeIsObject.get()); emitThrowTypeError(ASCIILiteral("Expected Object")); emitLabel(typeIsObject.get()); This will get split into a basic block in the DFG, which might slow down compile times or prevent some optimizations. I'm not exactly sure on the semantics we want. Do we want to do toBoolean on the condition or do we want to assume it's a boolean already? We should also figure out if we want to allow this bytecode to throw different types of exceptions. I think we really only throw type errors however.
Attachments
Add attachment
proposed patch, testcase, etc.
Note
You need to
log in
before you can comment on or make changes to this bug.
Top of Page
Format For Printing
XML
Clone This Bug