Uploaded image for project: 'JDK'
  1. JDK
  2. JDK-6610567

Please give us back the jsr bytecode

    XMLWordPrintable

Details

    • Enhancement
    • Status: Closed
    • P4
    • Resolution: Not an Issue
    • 6
    • None
    • specification
    • vm
    • x86
    • linux

    Description

      A DESCRIPTION OF THE REQUEST :
      In Java SE 6, the bytecodes jsr and jsr_w are no longer allowed.

      Even though they are no longer used by javac, compilers for other languages than Java might need jsr, jsr_w and ret. So please restore support for the bytecodes jsr, jsr_w and ret.


      JUSTIFICATION :
      Nowadays it's common to compile other languages than Java to JVM byte code, and in some cases it might be useful to compile a whole program into a single JVM method, since the Java invoke method style is incompatible with the language you want to compile. Procedures/functions/methods can then be implemented using the jsr (or jsr_w) and ret bytecodes.

      Some say that the new invokedynamic bytecode will solve this. It will certainly be a good solution for some languages, such as Python and Ruby. But I'm not sure that it will work smoothly for languages that are even more different, such as Haskell or Prolog.

      This RFE is connected to RFE #4262078 about increasing the maximum method size. Both are needed in order to provide good support for compiling other languages to JVM bytecode.

      Attachments

        Activity

          People

            abuckley Alex Buckley
            ryeung Roger Yeung (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:
              Imported:
              Indexed: