Bug 143374

Summary: FTL JIT tests should fail if LLVM library isn't available
Product: WebKit Reporter: Csaba Osztrogonác <ossy>
Component: JavaScriptCoreAssignee: Csaba Osztrogonác <ossy>
Status: RESOLVED FIXED    
Severity: Normal CC: fpizlo, mark.lam, msaboff, ossy
Priority: P2    
Version: 528+ (Nightly build)   
Hardware: Unspecified   
OS: Unspecified   
Bug Depends on:    
Bug Blocks: 143376    
Attachments:
Description Flags
Patch
none
Patch
none
Patch none

Description Csaba Osztrogonác 2015-04-03 06:19:23 PDT
Now run-javascriptcore-tests --ftl-jit tests pass if libllvmForJSC.so isn't available.
It isn't good that JSC silently falls back to non FTL path, because we can easily 
think that FTL is working well and all tests pass. ( It is related to bug143372 . )

Additionally now we can run FTL tests if we built JSC with disabled FTL.
It would be good to get error in this case too.
Comment 1 Csaba Osztrogonác 2015-04-03 08:14:30 PDT
(In reply to comment #0)
> Now run-javascriptcore-tests --ftl-jit tests pass if libllvmForJSC.so isn't
> available.
> It isn't good that JSC silently falls back to non FTL path, because we can
> easily 
> think that FTL is working well and all tests pass. ( It is related to
> bug143372 . )

I think JSC should crash with an error message if we execute it with
run-javascriptcore-tests and fall back to non FTL path in production code.

> Additionally now we can run FTL tests if we built JSC with disabled FTL.
> It would be good to get error in this case too.

I'm going to fix it later in a separated bug.
Comment 2 Csaba Osztrogonác 2015-04-03 08:16:20 PDT
Created attachment 250072 [details]
Patch
Comment 3 Csaba Osztrogonác 2015-04-03 08:20:05 PDT
Comment on attachment 250072 [details]
Patch

View in context: https://bugs.webkit.org/attachment.cgi?id=250072&action=review

> Source/JavaScriptCore/dfg/DFGPlan.cpp:418
> +            if (Options::ftlCrashesIfCantInitilizeLLVM()) {

typo: initi_a_lize
Comment 4 Csaba Osztrogonác 2015-04-03 08:20:52 PDT
Created attachment 250073 [details]
Patch

typo fixed
Comment 5 Mark Lam 2015-04-03 08:23:21 PDT
Comment on attachment 250073 [details]
Patch

View in context: https://bugs.webkit.org/attachment.cgi?id=250073&action=review

> Source/JavaScriptCore/dfg/DFGPlan.cpp:418
> +            if (Options::ftlCrashesIfCantInitilizeLLVM()) {

typo: Initilize

> Source/JavaScriptCore/runtime/Options.h:174
> +    v(bool, ftlCrashesIfCantInitailizeLLVM, false, nullptr) \

typo: Initailize
Comment 6 Csaba Osztrogonác 2015-04-03 08:25:52 PDT
Created attachment 250075 [details]
Patch

really fix the typo now
Comment 7 Mark Lam 2015-04-03 08:31:04 PDT
Comment on attachment 250075 [details]
Patch

r=me
Comment 8 Csaba Osztrogonác 2015-04-03 09:02:26 PDT
Comment on attachment 250075 [details]
Patch

Clearing flags on attachment: 250075

Committed r182318: <http://trac.webkit.org/changeset/182318>
Comment 9 Csaba Osztrogonác 2015-04-03 09:02:35 PDT
All reviewed patches have been landed.  Closing bug.