Hi! I'm developing package of multidimensional arrays according to JSR-83 and I want it to be optimized in JIT-compiler. The idea is to eliminate redundant boundchecks in a sort of way already implemented ABCD algorithm eliminates redundant boundchecks in one-dimensional arrays.
So I need to implement a special instruction in translator/IRBuilder for multiarray boundcheck. But there's a problem: I need some field descriptors of my class "DoubleMultiArray3D" to generate operands for the instruction (exactly, the capacities of array). There is a method "resolveField" in CompilationInterface, but it takes index in constant pool as operand - and I don't know index at that moment. I know just string name of the field. I tried the following: to get pointer to struct Class by "methodGetClass" function of JavaByteCodeTranslator - Struct Class has pointer to array of fields as member - and then find proper field in array of fields. But this last "field" pointer turned out to point to uninitialized memory. Such behavior is strange because almost the same code written in Class.cpp file allows working with fields (the same memory is initialized in a proper way). Something fatal happens while returning Class pointer to translator. I'll appreciate any suggestions on how to get field descriptor in translator, if I know the name of field and have pointer to Class. ------ Maksim --------------------------------------------------------------------- Terms of use : http://incubator.apache.org/harmony/mailing.html To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
