Return-Path: Delivered-To: apmail-harmony-commits-archive@www.apache.org Received: (qmail 5707 invoked from network); 5 Feb 2008 13:16:33 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (140.211.11.2) by minotaur.apache.org with SMTP; 5 Feb 2008 13:16:33 -0000 Received: (qmail 25906 invoked by uid 500); 5 Feb 2008 13:16:25 -0000 Delivered-To: apmail-harmony-commits-archive@harmony.apache.org Received: (qmail 25885 invoked by uid 500); 5 Feb 2008 13:16:25 -0000 Mailing-List: contact commits-help@harmony.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@harmony.apache.org Delivered-To: mailing list commits@harmony.apache.org Received: (qmail 25876 invoked by uid 99); 5 Feb 2008 13:16:25 -0000 Received: from nike.apache.org (HELO nike.apache.org) (192.87.106.230) by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 05 Feb 2008 05:16:25 -0800 X-ASF-Spam-Status: No, hits=-100.0 required=10.0 tests=ALL_TRUSTED X-Spam-Check-By: apache.org Received: from [140.211.11.4] (HELO brutus.apache.org) (140.211.11.4) by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 05 Feb 2008 13:16:17 +0000 Received: from brutus (localhost [127.0.0.1]) by brutus.apache.org (Postfix) with ESMTP id 3C4FE71406E for ; Tue, 5 Feb 2008 05:16:09 -0800 (PST) Message-ID: <28713387.1202217369243.JavaMail.jira@brutus> Date: Tue, 5 Feb 2008 05:16:09 -0800 (PST) From: "Alexey Varlamov (JIRA)" To: commits@harmony.apache.org Subject: [jira] Commented: (HARMONY-5142) [drlvm][verifier] initial implementation of recompute stackmap In-Reply-To: <12999960.1195298922994.JavaMail.jira@brutus> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit X-Virus-Checked: Checked by ClamAV on apache.org [ https://issues.apache.org/jira/browse/HARMONY-5142?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12565738#action_12565738 ] Alexey Varlamov commented on HARMONY-5142: ------------------------------------------ Added a placeholder for building static library for the verifier extensions at r618637: working_vm\make\vm\verifier-ext.xml The "verifier-ext" library will be available in HDK bundles under /lib directory. > [drlvm][verifier] initial implementation of recompute stackmap > -------------------------------------------------------------- > > Key: HARMONY-5142 > URL: https://issues.apache.org/jira/browse/HARMONY-5142 > Project: Harmony > Issue Type: New Feature > Components: DRLVM > Reporter: Mikhail Loenko > Attachments: recompute.zip > > > Here is an initial implementation of recompute stackmap by Eclipse TPTP request > ==================== > Currently Requires: > methods necessary to implement in addition to the standard class interface: > //returns index of class entry in the constant pool (extends constant pool if necessary) > uint16 class_get_cp_class_entry(class_handler k_class, const char* name); > //removes exception handler > void method_remove_exc_handler( method_handler method, unsigned short idx ); > //modifies existing exception handler info > void method_modify_exc_handler_info( method_handler method, unsigned short idx, unsigned short start_pc, > unsigned short end_pc, unsigned short handler_pc, unsigned short handler_cp_index ); > class_is_extending_class needs to be adjusted according to HARMONY-5141 > ================== > Current Usage Example: > vf_Result > instrument_class( class_handler klass, char **error ) > { > int index; > vf_Result result = VF_OK; > // Create contexts > SharedClasswideData classwide(klass); > vf_Context_6 context6(classwide); > // we may both use the same context for all methods in the class or create it each time for a next method > for( index = 0; index < class_get_method_number( klass ); index++ ) { > method_handler method = class_get_method( klass, index ); > //partially verifiy original code (and record trusted pairs) > result = context6.verify_method(method); > if (result != VF_OK) { > //original code was broken > *error = &(err_message[0]); > sprintf(*error, "%s/%s%s, reason: %s", class_get_name( klass ), method_get_name( method ), > method_get_descriptor( method ), context6.error_message ); > return result; > } > ////// INSTRUMENT CODE HERE > //calculate new stackmap > uint8 *stackmap; > result = vf_recompute_stackmaptable(method, &stackmap, error, classwide.class_constraints); > if (result != VF_OK) { > // report a problem > } > //USE NEW stackmap > //free it somewhere later > free(stackmap); > } > return result; > } -- This message is automatically generated by JIRA. - You can reply to this email to add a comment to the issue online.