What are the opcodes that put vars on the local frame array? Remove them?

Does anyone know of a reference that lists all the opcodes that put a local variable in the local frame array (like ASTORE, BIPUSH, etc) and all the ones that remove them (like POP, ALOAD, etc)?

BIPUSH doesn't affect the frame, it pushes a value onto the operand stack. The distinction may be subtle, but it's
important since the JVM is a stack-based architecture (in other words, if you don't make the distinction, than your
list contains [almost] all of the JVM opcodes).You're right. So then, what exactly are POP, DUP, etc doing? Are they taking from the frame?First thing to remember is that the frame and operand stack are logically different: the frame contains method parameters and local variables, while the operand stack is used for intermediate results. They may be implemented using a single processor stack (in X86 terms, the BP register would point to the start of the frame, while pushes and pops would modify the SP), but don't have to be. I think the JVM spec even talks about storing frames in the heap.
Here's an example:
public static int foo(int a, int b)
    int c = a + b;
    int d = (c + c) * 5;
    return d;
}Running javap -c to show the bytecodes, we get this:
public static int foo(int, int);
  Code:
   0:   iload_0
   1:   iload_1
   2:   iadd
   3:   istore_2
   4:   iload_2
   5:   iload_2
   6:   iadd
   7:   iconst_5
   8:   imul
   9:   istore_3
   10:  iload_3
   11:  ireturnThe two method parameters, a and b, are stored in the frame in slot 0 and 1 (if this were an instance method, slot 0 would contain "this"). They get pushed onto the stack using the iload opcode (the normal version of this opcode takes a second byte index into the frame; to minimize code size, the JVM has alternate versions of most frame-access opcodes that are hardcoded for a specific low-numbered slots).
After the loads, the stack will contain the values held in b and a; the iadd instruction adds these together, leaving the result on the stack. The istore_2 removes the topmost value from the operand stack, and stores it in the frame (in the slot assigned to variable "c").
To your question about dup and so forth, I was hoping to demonstrate that with the repeated reference to variable "c"; instead, the compiler translated that into the two iload operations (opcodes 4 and 5). I suppose it makes sense, but it shows just how little optimization the compiler attempts to do -- instead, it relies on Hotspot being smart enough to optimize hardware accesses.
The iconst_5 opcode is another example of something that affects the operand stack but not the frame: it pushes a hardcoded constant value onto the stack.
It's also another case where the JVM defines several opcodes that do the same thing: the iconst_n for values -1 to 5, bipush for values that are outside this range but still smaller than a byte, sipush for values that will fit into a short, and ldc for everything else. The goal is efficient code generation: 1-3 bytes for most of the integer values that you're likely to load. The ldc opcode is interesting in its own right: it does a lookup into a per-class table to find the value to push. Not very efficient in terms of CPU cycles and memory access (although it can be inlined by Hotspot), but again efficient from a bytecode perspective: if you're loading a large constant, there's at least a chance that you'll be loading it multiple times.
Chapter 6 of the VM spec lists all the opcodes, and I seem to remember groupings by purpose: http://
java.sun.com/docs/books/jvms/second_edition/html/Instructions.doc.htmlUnfortunately, it doesn't quite do that. They're mostly all in the same place on the summary page but not quite all. (For example, the array ones were in a separate place) And the link you posted lists them only alphabetically.Yeah, but jverd posted the link to section 3.11, which groups the opcodes. You probably want 3.11.2: http://java.sun.com/docs/books/jvms/second_edition/html/Overview.doc.html#6348
Which leads to the more interesting question: why?

Similar Messages

  • What are the MDM Modes and explain them?

    hi friends,
    What are the MDM Modes
    please explain each mode with examples?
    thanks and regards,
    ramu.

    Hi,
    There are five modes in Data Manager which are as follows:
    1. Record Mode: When Data Manager starts, record mode is opened.It is the primary working view. From here, the content of the data can be
    managed. We perform various operations like
    a. Adding a record
    b. Deleting a record
    c. Searching a record. The search for a record in record mode can be started from the tree view located in the left area of the main window. The search parameters are shown here.
    2. Hierarchy Mode: In this mode, the user of the Data Manager can view and change all hierarchies stored in the repository. The hierarchy table to be edited can be selected here. The tree view displays the tree structure of the hierarchy.
    3. Taxonomy Mode:  The taxonomy determines how records belonging to different categories are defined. Through a taxonomy, an attribute can be attached to a record. These additional attributes are defined for records, which belong to a certain category. An example of this could be personal data, which differs according to the role in the organization, and thus includes additional information.
    The taxonomy mode can only be selected if there is a table of type Taxonomy in the repository.
    4. Matching Mode:  We can define transformations, substitutions, and matching rules u2014 and bundle these rules into matching strategies.
    According to a matching strategy, for example, SAP net weaver MDM will calculate scores for the probability that specific records are duplicates. We can then compare potential duplicates and merge any objects that are in fact repeated.
    In Rules Tab, we set up rules to automate the detection of duplicate master data.
    In Strategies tab, we bundle rules into matching strategies to calculate the probability of duplicates.
    A high matching score indicates that a data entry is likely a duplicate record.
    5. Family Mode: In family mode, all existing records that are already assigned to a category can be subdivided into families. The taxonomy table in which the family definitions are to be stored is selected in the toolbar. Then the family can be selected in the tree view.
    Regards
    Richa

  • Personas- what are the settings required to make them display

    I have an XP machine where personas only show as a solid color. I have a WIN 7 machine with multiple users - some users work fine and some switch off and on between working and showing only a solid color. I want to know the config settings to look at and compare across platforms and users to get all working again. I am on the current version of FIREFOX - this started about 4 updates ago and has remained.

    Does this happen with all lightweight themes (Personas)?
    Do those computers use the default theme in Firefox because a custom theme may not work with Personas?
    Create a new profile as a test to check if your current profile is causing the problem.
    See "Creating a profile":
    *https://support.mozilla.org/kb/profile-manager-create-and-remove-firefox-profiles
    *http://kb.mozillazine.org/Standard_diagnostic_-_Firefox#Profile_issues
    If the new profile works then you can transfer files from a previously used profile to the new profile, but be cautious not to copy corrupted files to avoid carrying over problems.
    *http://kb.mozillazine.org/Transferring_data_to_a_new_profile_-_Firefox

  • What are the major differences b/w DTP & Infopackage

    HI Experts,
    what are the  major benifits of DTP over Infopackages????  also what are the major differences b/w them ????
    Cheers
    Swaps

    Since you are talking of DTP's, I assume you are working on BI 7
    In BI 7:
    Infopackage- is used to pull data from the source system to the PSA. PSA is compulsory in BI 7. Beyond this infopackage doesn't play any role.
    DTP: DTP's are used to transfer data from one data provider to another.
    it can be
    PSA - DSO/Cube
    Cube - CUbe
    DSO - Cube
    DSO - DSO and so on
    Hope this helps
    Godhuli

  • What are the right names for the 2 OHS?

    Hi,
    Currently we have 2 options for an HTTP Web Server for APEX:
    - An Oracle HTTP Server (OHS) from the database companion CD.
    - An Oracle HTTP Server (OHS) from the Oracle Application Server.
    The first OHS is based on Apache 1.3.x and the second on Apache 2.0.x.
    What are the right way to reference them so people know what your are talking about? In the manuals they are just called OHS but since they are not the same I would like to distinguish them some way. What do you call them?
    Regards Pete

    OK now I think got it:
    OHS from the database companion CD and from the Application Server are both based on an Apache 1.3.x HTTP server.
    On the Oracle Application Server companion CD is an OHS based on an Apache 2.0.x HTTP server. This release does not contain the mod_plsql module an can therefor not be used for APEX.
    Regards Pete

  • The answer helped me.But still, what are the settings that I have to change for the behavior of the mouse pointer towards finder? Also the mouse pointer sometimes  doesn't accept my command and start clicking itself.what is the problem and how to fix it?

    The answer helped me.But still, what are the settings that I have to change for the behavior of the mouse pointer towards finder? Also the mouse pointer sometimes  doesn't accept my command and start clicking itself.what is the problem and how to fix it?

    If the mouse clicks something on its own then it looks like you have a hardware problem with the trackpad or possibly the battery that is right underneath the trackpad.
    I have read that the battery can swell and that would put pressure on the trackpad.

  • What are the largest sized memory cards that can be swapped into a macmini 2.6GHz i7 quadcore

    What are the largest sized replacement memory cards that can be used in a new macmini 2.6MHz i7 quad core? I see samsung has some 16GB cards and was wondering if the macmini can be jacked up to 32GB instead of the apple store configuration of 2x8GB or 16GB total.

    I called Apple Support cause I just purchased my Macmini and found out that it is a memory stick slot issue of some sort. If there were 4 slots instead of two, then you could have 32GB of memory. So it appears to be a board layout issue when apple layed out the processor board they did not allow for enough address bus width for the memory slots cause the intel processor chip will support up to 32GB of memory. Apparently others have tried to put 2x16GB into macminis and have all been unsuccessful thus far. I guess someone could go in and whitewire their processor board but that would be insanely over the top. :-)

  • What are the PDA or phone that supporte java ????

    what are the PDA or phone that supporte java ????
    I want to integrate a java application, but tryed to integred on the Mondo Trium with Pjava, so it's too slow, is there any phone or PDA than supported my application
    My application download some maps from server and put up on panel, so it required a good machine ?????
    Please Help !!!!!

    You could try Personal JAVA with WinCE 2.11
    http://java.sun.com/products/personaljava/

  • What are the general properties that must be in target machine for clone ?

    What are the general properties that must be in target machine for clone ?
    like must intall EBS frist.
    must have same users name
    must run in the same linex .
    etc..

    Hi Micel,
    Thanks for the OS version Update
    Micel 811 wrote:
    sourse :Red Hat Enterprise Linux Server release 5.3
    Target :Red Hat Enterprise Linux Server release 6.0 (Santiago)
    is there problem with this differences ?Yes
    whats your EBS version?
    assuming you are on R12
    You need to upgrade the database to 11.2.0.3 and Oracle Application Server 10gR3 to 10.1.3.5 -- See the following docs for details.
    Oracle E-Business Suite Installation and Upgrade Notes Release 12 (12.1.1) for Linux x86 [ID 761564.1]
    Oracle E-Business Suite Installation and Upgrade Notes Release 12 (12.1.1) for Linux x86-64 [ID 761566.1]
    and can i take clone for tow nodes and put in one node ?Yes
    Already answered in my last post
    FAQ: Cloning Oracle Applications Release 11i [ID 216664.1]
    have you refered the doc above ?
    and As I understand I do not need to new fresh EBS setup for target node.Yes No need ;)
    Beauty of Rapid clone :P
    ;) Appsmasti ;)
    Sharing is Caring

  • My ipad mini was stolen and i have activated the find my phone to lock it. how can i get the serial number off my itunes or icloud profile? and what are the chances that the find my iphone app works when someome erases the device?

    my ipad mini has been stolen and i have activated the find my iphone to lock. now it is only a wifi device so what are the chances that a person can get hold of it and log onto wifi without the password of my device to unlock. does that not make the app rather less useful as i have to hope that the person is apt enough to log onto the internet but not enough to erase it and start afresh. is it possible to find my device even afte someone has erased it?

    "Losing your iPhone feels lousy. Thankfully, iCloud can help you get it back. But if it looks like that’s not going to happen, new Find My iPhone features in iOS 7 make it harder for anyone who’s not you to use or sell your device. Now turning off Find My iPhone or erasing your device requires your Apple ID and password. Find My iPhone can also continue to display a custom message, even after your device is erased. And your Apple ID and password are required before anyone can reactivate it."
    http://www.apple.com/icloud/features/#fmip

  • I have created a quotation in CRM system. I want that to be downloaded into ECC, so that, I can create a sales order there with reference to that quotation. So, what are the parameters that I need to set in CRM system so that my quotation gets replicated?

    Dear Experts,
    I have created a quotation in CRM system. I want that to be downloaded into ECC, so that, I can create a sales order there with reference to that quotation. What are the parameters that I need to set in CRM system so that my quotation gets replicated without any error?
    Please help me in this regard. An early and in detail step by step guidance is highly appreciated.
    Thanks,
    SMTP

    It may be best to recreate the folder and the smart playlists from scratch.
    tt2

  • What are the models of nokia that has 3d graphic a...

    What are the models of nokia that has 3d graphic acceleration??

    yep petrib u are 100% correct. i dont see why they did not add 3D Acc. in N96.
    If you find my post useful then click on
    Kudos!Nokia N96 (v20.050 / RM-247)
    www.shaysoft.net | Competitions!

  • What are the implications of using jquery version 1.10.2 rather than the version (1.7.1) that Adobe

    What are the implications of using jquery version 1.10.2 rather than the version (1.7.1) that Adobe uses? Thanks
    Bob

    I am having trouble when my Edge Animate composition (banner ad) appears on a web page that uses jquery version 1.8.23. Some of the functionality of the host page no longer works. This occurs only when my composition is present & the functionality returns when another ad is displayed (either a Flash ad or a gif). It happens in Chrome Version 31.0.1650.63 m, Chrome Version 33.0.1738.0 canary & IE 11.
    I had edited my Edge Animate files to use the Adobe CDN option & to point to another server (mine) so only the html file was needed to be placed in the ad rotator & on the host's server. I now have edited them again to include the Google CDN locations for version jquery 1.10.2 (http://ajax.googleapis.com/ajax/libs/jquery/1.10.2/jquery.min.js). I am waiting for the host site to try this updated html file. When I visit just this new page & the old one that pointed to 1.7.1 for that matter, it works fine.
    Thank you for taking the time to read and answer my message.
    Bob

  • What are the T-codes that contain the master data for material and vendor?

    what are the T-codes that contain the master data for material and vendor?

    hi ,
    - Display Material  tcodes...
    MM01 - Create Material
    MM02 - Change Material
    MM03 - Display Material
    MM50 - List Extendable Materials
    MMBE - Stock Overview
    MMI1 - Create Operating Supplies
    MMN1 - Create Non-Stock Material
    MMS1 - Create Service
    MMU1 - Create Non-Valuated Material
    ME51N - Create Purchase Requisition
    ME52N - Change Purchase Requisition
    ME53N - Display Purchase Requisition
    ME5A - Purchase Requisitions: List Display
    ME5J - Purchase Requisitions for Project
    ME5K - Requisitions by Account Assignment
    MELB - Purch. Transactions by Tracking No.
    ME56 - Assign Source to Purch. Requisition
    ME57 - Assign and Process Requisitions
    ME58 - Ordering: Assigned Requisitions
    ME59 - Automatic Generation of POs
    ME54 - Release Purchase Requisition
    ME55 - Collective Release of Purchase Reqs.
    ME5F - Release Reminder: Purch. Requisition
    MB21 - Create Reservation
    MB22 - Change Reservation
    MB23 - Display Reservation
    MB24 - Reservations by Material
    MB25 - Reservations by Account Assignment
    MB1C - Other Goods Receipts
    MB90 - Output Processing for Mat. Documents
    MB21 - Create Reservation
    MB22 - Change Reservation
    MB23 - Display Reservation
    MB24 - Reservations by Material
    MB25 - Reservations by Account Assignment
    MBRL - Return Delivery per Mat. Document
    MB1C - Other Goods Receipts
    MB90 - Output Processing for Mat. Documents
    MB1B - Transfer Posting
    MIBC - ABC Analysis for Cycle Counting
    MI01 - Create Physical Inventory Document
    MI02 - Change Physical Inventory Document
    MI03 - Display Physical Inventory Document
    MI31 - Batch Input: Create Phys. Inv. Doc.
    MI32 - Batch Input: Block Material
    MI33 - Batch Input: Freeze Book Inv.Balance
    MICN - Btch Inpt:Ph.Inv.Docs.for Cycle Ctng
    MIK1 - Batch Input: Ph.Inv.Doc.Vendor Cons.
    MIQ1 - Batch Input: PhInvDoc. Project Stock
    MI01 - Create Physical Inventory Document
    MI02 - Change Physical Inventory Document
    MI03 - Display Physical Inventory Document
    MI31 - Batch Input: Create Phys. Inv. Doc.
    MI32 - Batch Input: Block Material
    MI33 - Batch Input: Freeze Book Inv.Balance
    MICN - Btch Inpt:Ph.Inv.Docs.for Cycle Ctng
    MIK1 - Batch Input: Ph.Inv.Doc.Vendor Cons.
    MIQ1 - Batch Input: PhInvDoc. Project Stock
    MI01 - Create Physical Inventory Document
    MI02 - Change Physical Inventory Document
    MI03 - Display Physical Inventory Document
    MI31 - Batch Input: Create Phys. Inv. Doc.
    MI32 - Batch Input: Block Material
    MI33 - Batch Input: Freeze Book Inv.Balance
    MICN - Btch Inpt:Ph.Inv.Docs.for Cycle Ctng
    MIK1 - Batch Input: Ph.Inv.Doc.Vendor Cons.
    MIQ1 - Batch Input: PhInvDoc. Project Stock
    MI21 - Print physical inventory document
    MI04 - Enter Inventory Count with Document
    MI05 - Change Inventory Count
    MI06 - Display Inventory Count
    MI09 - Enter Inventory Count w/o Document
    MI34 - Batch Input: Enter Count
    MI35 - Batch Input: Post Zero Stock Balance
    MI38 - Batch Input: Count and Differences
    MI39 - Batch Input: Document and Count
    MI40 - Batch Input: Doc., Count and Diff.
    MI08 - Create List of Differences with Doc.
    MI10 - Create List of Differences w/o Doc.
    MI20 - Print List of Differences
    MI11 - Physical Inventory Document Recount
    MI07 - Process List of Differences
    MI37 - Batch Input: Post Differences
    for vendor..
    XKN1  Display Number Ranges (Vendor)
    XK01  Create vendor (centrally)
    XK02  Change vendor (centrally)
    XK03  Display vendor (centrally)
    XK04  Vendor Changes (Centrally)
    XK05  Block Vendor (Centrally)
    XK06 Mark vendor for deletion (centrally
    XK07  Change vendor account group
    XK11  Create Condition
    XK12  Change Condition
    XK13  Display Condition
    XK14  Create with cond. ref. (cond. list)
    XK15  Create Conditions (background job)
    reward points if useful,
    venkat.

  • What are the Master data that should be uploaded for Go live

    Can any one tell me what are the SD master data that should be uploaded during GO live

    Hi Prem,
    SD Master data includes:
    - Customer Master data
    - Material Master data
    - Customer-Material Info records
    - Enterprise Structure info (Dist Channels,Divisions etc)
    - Condition Master Data in Pricing.
    I believe, all these need to be uploaded during GO Live.
    regards,
    Raj

Maybe you are looking for