You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Running jruby 9.1.7.0 (2.3.1) 2017-01-11 68056ae Java HotSpot(TM) 64-Bit Server VM 25.111-b14 on 1.8.0_111-b14 +jit [linux-x86_64] on Linux maruchan 4.9.0-11-generic #12-Ubuntu SMP Mon Dec 12 16:18:23 UTC 2016 x86_64 x86_64 x86_64 GNU/Linux.
Expected Behavior
Example testcase:
require'grape'classFoo < Grape::APIpost{}end
(Attached version includes Gemfile and Gemfile.lock: testcase.zip)
When running under JRuby normally, this code has no problems.
Actual Behavior
When running this code with jruby -Xreify.classes=true test.rb it results in the following exception:
Unhandled Java exception: java.lang.NoSuchMethodError: rubyobj.Grape.Util.InheritableValues.callMethod(Ljava/lang/String;Lorg/jruby/runtime/builtin/IRubyObject;)Lorg/jruby/runtime/builtin/IRubyObject;
java.lang.NoSuchMethodError: rubyobj.Grape.Util.InheritableValues.callMethod(Ljava/lang/String;Lorg/jruby/runtime/builtin/IRubyObject;)Lorg/jruby/runtime/builtin/IRubyObject;
initialize_copy at rubyobj/Grape/Util/InheritableValues:-1
initialize_copy at org/jruby/RubyKernel.java:1836
call at org/jruby/RubyKernel$INVOKER$s$1$0$initialize_copy.gen:-1
call at org/jruby/internal/runtime/methods/JavaMethod.java:738
instanceSuper at org/jruby/ir/runtime/IRRuntimeHelpers.java:990
interpret at org/jruby/ir/instructions/InstanceSuperInstr.java:69
processCall at org/jruby/ir/interpreter/InterpreterEngine.java:356
interpret at org/jruby/ir/interpreter/StartupInterpreterEngine.java:73
interpret at org/jruby/ir/interpreter/InterpreterEngine.java:84
INTERPRET_METHOD at org/jruby/internal/runtime/methods/MixedModeIRMethod.java:179
call at org/jruby/internal/runtime/methods/MixedModeIRMethod.java:165
call at org/jruby/internal/runtime/methods/DynamicMethod.java:200
cacheAndCall at org/jruby/runtime/callsite/CachingCallSite.java:338
call at org/jruby/runtime/callsite/CachingCallSite.java:163
processCall at org/jruby/ir/interpreter/InterpreterEngine.java:315
interpret at org/jruby/ir/interpreter/StartupInterpreterEngine.java:73
interpret at org/jruby/ir/interpreter/InterpreterEngine.java:84
INTERPRET_METHOD at org/jruby/internal/runtime/methods/MixedModeIRMethod.java:179
call at org/jruby/internal/runtime/methods/MixedModeIRMethod.java:165
call at org/jruby/internal/runtime/methods/DynamicMethod.java:200
cacheAndCall at org/jruby/runtime/callsite/CachingCallSite.java:338
call at org/jruby/runtime/callsite/CachingCallSite.java:163
initCopy at org/jruby/RubyBasicObject.java:911
rbClone at org/jruby/RubyBasicObject.java:963
rbClone at org/jruby/RubyKernel.java:1881
call at org/jruby/RubyKernel$INVOKER$s$0$0$rbClone.gen:-1
cacheAndCall at org/jruby/runtime/callsite/CachingCallSite.java:318
call at org/jruby/runtime/callsite/CachingCallSite.java:131
processCall at org/jruby/ir/interpreter/InterpreterEngine.java:340
interpret at org/jruby/ir/interpreter/StartupInterpreterEngine.java:73
INTERPRET_BLOCK at org/jruby/ir/interpreter/Interpreter.java:132
commonYieldPath at org/jruby/runtime/MixedModeIRBlockBody.java:148
doYield at org/jruby/runtime/IRBlockBody.java:182
yield at org/jruby/runtime/BlockBody.java:111
yield at org/jruby/runtime/Block.java:167
tap at org/jruby/RubyKernel.java:1747
call at org/jruby/RubyKernel$INVOKER$s$0$0$tap.gen:-1
call at org/jruby/internal/runtime/methods/JavaMethod.java:497
cacheAndCall at org/jruby/runtime/callsite/CachingCallSite.java:298
callBlock at org/jruby/runtime/callsite/CachingCallSite.java:79
call at org/jruby/runtime/callsite/CachingCallSite.java:83
interpret at org/jruby/ir/instructions/CallBase.java:428
processCall at org/jruby/ir/interpreter/InterpreterEngine.java:356
interpret at org/jruby/ir/interpreter/StartupInterpreterEngine.java:73
interpret at org/jruby/ir/interpreter/InterpreterEngine.java:78
INTERPRET_METHOD at org/jruby/internal/runtime/methods/MixedModeIRMethod.java:144
call at org/jruby/internal/runtime/methods/MixedModeIRMethod.java:130
call at org/jruby/internal/runtime/methods/DynamicMethod.java:192
cacheAndCall at org/jruby/runtime/callsite/CachingCallSite.java:318
call at org/jruby/runtime/callsite/CachingCallSite.java:131
processCall at org/jruby/ir/interpreter/InterpreterEngine.java:340
interpret at org/jruby/ir/interpreter/StartupInterpreterEngine.java:73
INTERPRET_METHOD at org/jruby/internal/runtime/methods/MixedModeIRMethod.java:109
call at org/jruby/internal/runtime/methods/MixedModeIRMethod.java:95
cacheAndCall at org/jruby/runtime/callsite/CachingCallSite.java:298
callBlock at org/jruby/runtime/callsite/CachingCallSite.java:79
call at org/jruby/runtime/callsite/CachingCallSite.java:83
newInstance at org/jruby/RubyClass.java:1022
call at org/jruby/RubyClass$INVOKER$i$newInstance.gen:-1
instanceSuper at org/jruby/ir/runtime/IRRuntimeHelpers.java:990
interpret at org/jruby/ir/instructions/InstanceSuperInstr.java:69
processCall at org/jruby/ir/interpreter/InterpreterEngine.java:356
interpret at org/jruby/ir/interpreter/StartupInterpreterEngine.java:73
INTERPRET_METHOD at org/jruby/internal/runtime/methods/MixedModeIRMethod.java:109
call at org/jruby/internal/runtime/methods/MixedModeIRMethod.java:95
cacheAndCall at org/jruby/runtime/callsite/CachingCallSite.java:298
callBlock at org/jruby/runtime/callsite/CachingCallSite.java:79
call at org/jruby/runtime/callsite/CachingCallSite.java:83
interpret at org/jruby/ir/instructions/CallBase.java:428
processCall at org/jruby/ir/interpreter/InterpreterEngine.java:356
interpret at org/jruby/ir/interpreter/StartupInterpreterEngine.java:73
INTERPRET_METHOD at org/jruby/internal/runtime/methods/MixedModeIRMethod.java:109
call at org/jruby/internal/runtime/methods/MixedModeIRMethod.java:95
cacheAndCall at org/jruby/runtime/callsite/CachingCallSite.java:298
callBlock at org/jruby/runtime/callsite/CachingCallSite.java:79
call at org/jruby/runtime/callsite/CachingCallSite.java:83
interpret at org/jruby/ir/instructions/CallBase.java:428
processCall at org/jruby/ir/interpreter/InterpreterEngine.java:356
interpret at org/jruby/ir/interpreter/StartupInterpreterEngine.java:73
INTERPRET_METHOD at org/jruby/internal/runtime/methods/MixedModeIRMethod.java:109
call at org/jruby/internal/runtime/methods/MixedModeIRMethod.java:95
cacheAndCall at org/jruby/runtime/callsite/CachingCallSite.java:298
callBlock at org/jruby/runtime/callsite/CachingCallSite.java:79
call at org/jruby/runtime/callsite/CachingCallSite.java:83
interpret at org/jruby/ir/instructions/CallBase.java:428
processCall at org/jruby/ir/interpreter/InterpreterEngine.java:356
interpret at org/jruby/ir/interpreter/StartupInterpreterEngine.java:73
INTERPRET_BLOCK at org/jruby/ir/interpreter/Interpreter.java:132
commonYieldPath at org/jruby/runtime/MixedModeIRBlockBody.java:148
call at org/jruby/runtime/IRBlockBody.java:69
call at org/jruby/runtime/Block.java:126
call at org/jruby/RubyProc.java:289
call at org/jruby/internal/runtime/methods/ProcMethod.java:63
call at org/jruby/internal/runtime/methods/DynamicMethod.java:196
cacheAndCall at org/jruby/runtime/callsite/CachingCallSite.java:328
callBlock at org/jruby/runtime/callsite/CachingCallSite.java:141
call at org/jruby/runtime/callsite/CachingCallSite.java:145
invokeOther3:post at test.rb:4
<class:Foo> at test.rb:4
call at org/jruby/internal/runtime/methods/CompiledIRMethod.java:77
call at org/jruby/internal/runtime/methods/CompiledIRMethod.java:87
invokeModuleBody at org/jruby/ir/runtime/IRRuntimeHelpers.java:1422
<main> at test.rb:3
invokeWithArguments at java/lang/invoke/MethodHandle.java:627
load at org/jruby/ir/Compiler.java:90
runScript at org/jruby/Ruby.java:823
runNormally at org/jruby/Ruby.java:742
runNormally at org/jruby/Ruby.java:760
runFromMain at org/jruby/Ruby.java:573
doRunFromMain at org/jruby/Main.java:417
internalRun at org/jruby/Main.java:305
run at org/jruby/Main.java:232
main at org/jruby/Main.java:204
The text was updated successfully, but these errors were encountered:
I'm guessing this is a recent attempt to upgrade? The reify.classes feature has always been experimental. In particular, it has never worked properly with reify.variables which has been ON by default since JRuby 9.1. There's a separate issue tracking the breakage in reify.variables. It's most likely that they'll become the same setting internally in the future and we'll always reify classes, but that decision has not been made (since it will require generating many more JVM classes than we do today).
Can you give me some background about how you're using this feature? Are you doing it solely to be able to heap analyze a Ruby app?
I had left this setting on my .jrubyrc as I had been debugging some memory issues, and thought I'd leave it always on for my development machine.
If the breakage is known/being tracked elsewhere, feel free to close, as I'm definitely not using it in production (although as it is THE tool for analyzing heap dumps it definitely would be beyond awesome to be on by default, or at least be fully supported).
Environment
Running
jruby 9.1.7.0 (2.3.1) 2017-01-11 68056ae Java HotSpot(TM) 64-Bit Server VM 25.111-b14 on 1.8.0_111-b14 +jit [linux-x86_64]
onLinux maruchan 4.9.0-11-generic #12-Ubuntu SMP Mon Dec 12 16:18:23 UTC 2016 x86_64 x86_64 x86_64 GNU/Linux
.Expected Behavior
Example testcase:
(Attached version includes
Gemfile
andGemfile.lock
: testcase.zip)When running under JRuby normally, this code has no problems.
Actual Behavior
When running this code with
jruby -Xreify.classes=true test.rb
it results in the following exception:The text was updated successfully, but these errors were encountered: