Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Buggy IR built for const lookup instr inside a stabby lambda #2284

Closed
subbuss opened this issue Dec 6, 2014 · 3 comments
Closed

Buggy IR built for const lookup instr inside a stabby lambda #2284

subbuss opened this issue Dec 6, 2014 · 3 comments
Labels

Comments

@subbuss
Copy link
Contributor

subbuss commented Dec 6, 2014

Reproducible with this simple snippet:

class C
  class D; end
end

-> { C::D.new }.call

The IR built for the lookup of C is:

2014-12-06T17:06:48.228+05:30: InterpretedIRBlockBody: CFG:
BB [1:CL1_LBL_2:0]
BB [2:CL1_LBL_3:0]
        line_num(4)
        %v_0 = search_const(C, %v_1, no-private-consts=false)

Notice the %v_1 use without a corresponding definition for it.

This is the source of the two travis-core failures seen in https://travis-ci.org/travis-ci/travis-core/jobs/42825525

@subbuss subbuss added the ir label Dec 6, 2014
@subbuss subbuss added this to the JRuby 9.0.0.0-pre1 milestone Dec 6, 2014
@subbuss
Copy link
Contributor Author

subbuss commented Dec 6, 2014

@headius @enebo This bug opens up the potential for cleanup that I had been considering for a while. I had introduced the scope / module variable stuff long back so that we can exploit static information where available. However, as part of removing IRScope references for JIT, that basic intention has been a bit obscured.

In any case, will take a look at this later tonight and fix up the mixing initialization.

@subbuss subbuss closed this as completed in 5b14079 Dec 6, 2014
@subbuss
Copy link
Contributor Author

subbuss commented Dec 6, 2014

The bug is fixed, but let us chat later about cleaning up the CurrentScope/CurrentModule uses. I have a feeling get rid of the temporary variables and simplify some of that old code.

@enebo
Copy link
Member

enebo commented Dec 6, 2014

Awesome thanks subbu. You get back on what day?

-Tom

On Sat, Dec 6, 2014 at 6:27 AM, subbuss notifications@github.com wrote:

The bug is fixed, but let us chat later about cleaning up the
CurrentScope/CurrentModule uses. I have a feeling get rid of the temporary
variables and simplify some of that old code.


Reply to this email directly or view it on GitHub
#2284 (comment).

blog: http://blog.enebo.com twitter: tom_enebo
mail: tom.enebo@gmail.com

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants