com.apple.jobjc.Coder.StructCoder Java Examples
The following examples show how to use
com.apple.jobjc.Coder.StructCoder.
You can vote up the ones you like or vote down the ones you don't like,
and go to the original project or source file by following the links above each example. You may check out the related API usage on the sidebar.
Example #1
Source File: StructClassFile.java From dragonwell8_jdk with GNU General Public License v2.0 | 6 votes |
@Override public void writeBeginning(final PrintStream out) { out.println(); out.println("\tpublic static int SIZEOF = " + JObjCRuntime.class.getName() + ".IS64 ? " + ((NStruct) struct.type.type64).sizeof64() + " : " + ((NStruct) struct.type.type32).sizeof32() + ";"); out.println(); out.format("\tpublic final static %1$s getStructCoder(){ return coder; }\n", StructCoder.class.getCanonicalName()); out.format("\t@Override public final %1$s getCoder(){ return coder; }\n", StructCoder.class.getCanonicalName()); out.format("\tprivate final static %1$s coder = new %1$s(SIZEOF%2$s%3$s){\n", StructCoder.class.getCanonicalName(), (struct.fields.size() > 0 ? ",\n\t\t" : ""), Fp.join(",\n\t\t", Fp.map(new Map1<Field,String>(){ public String apply(Field a) { return a.type.getJType().getCoderDescriptor().getCoderInstanceName(); }}, struct.fields))); out.format("\t\t@Override protected %1$s newInstance(%2$s runtime){ return new %1$s(runtime); }\n", struct.name, JObjCRuntime.class.getCanonicalName()); out.println("\t};"); out.println(); out.println("\t" + struct.name + "(final " + JObjCRuntime.class.getCanonicalName() + " runtime){"); out.println("\t\tsuper(runtime, SIZEOF);"); out.println("\t}"); out.println(); out.println("\tpublic " + struct.name + "(final " + JObjCRuntime.class.getCanonicalName() + " runtime, final com.apple.jobjc.NativeBuffer buffer) {"); out.println("\t\tsuper(runtime, buffer, SIZEOF);"); out.println("\t}"); }
Example #2
Source File: StructClassFile.java From TencentKona-8 with GNU General Public License v2.0 | 6 votes |
@Override public void writeBeginning(final PrintStream out) { out.println(); out.println("\tpublic static int SIZEOF = " + JObjCRuntime.class.getName() + ".IS64 ? " + ((NStruct) struct.type.type64).sizeof64() + " : " + ((NStruct) struct.type.type32).sizeof32() + ";"); out.println(); out.format("\tpublic final static %1$s getStructCoder(){ return coder; }\n", StructCoder.class.getCanonicalName()); out.format("\t@Override public final %1$s getCoder(){ return coder; }\n", StructCoder.class.getCanonicalName()); out.format("\tprivate final static %1$s coder = new %1$s(SIZEOF%2$s%3$s){\n", StructCoder.class.getCanonicalName(), (struct.fields.size() > 0 ? ",\n\t\t" : ""), Fp.join(",\n\t\t", Fp.map(new Map1<Field,String>(){ public String apply(Field a) { return a.type.getJType().getCoderDescriptor().getCoderInstanceName(); }}, struct.fields))); out.format("\t\t@Override protected %1$s newInstance(%2$s runtime){ return new %1$s(runtime); }\n", struct.name, JObjCRuntime.class.getCanonicalName()); out.println("\t};"); out.println(); out.println("\t" + struct.name + "(final " + JObjCRuntime.class.getCanonicalName() + " runtime){"); out.println("\t\tsuper(runtime, SIZEOF);"); out.println("\t}"); out.println(); out.println("\tpublic " + struct.name + "(final " + JObjCRuntime.class.getCanonicalName() + " runtime, final com.apple.jobjc.NativeBuffer buffer) {"); out.println("\t\tsuper(runtime, buffer, SIZEOF);"); out.println("\t}"); }
Example #3
Source File: StructClassFile.java From jdk8u-dev-jdk with GNU General Public License v2.0 | 6 votes |
@Override public void writeBeginning(final PrintStream out) { out.println(); out.println("\tpublic static int SIZEOF = " + JObjCRuntime.class.getName() + ".IS64 ? " + ((NStruct) struct.type.type64).sizeof64() + " : " + ((NStruct) struct.type.type32).sizeof32() + ";"); out.println(); out.format("\tpublic final static %1$s getStructCoder(){ return coder; }\n", StructCoder.class.getCanonicalName()); out.format("\t@Override public final %1$s getCoder(){ return coder; }\n", StructCoder.class.getCanonicalName()); out.format("\tprivate final static %1$s coder = new %1$s(SIZEOF%2$s%3$s){\n", StructCoder.class.getCanonicalName(), (struct.fields.size() > 0 ? ",\n\t\t" : ""), Fp.join(",\n\t\t", Fp.map(new Map1<Field,String>(){ public String apply(Field a) { return a.type.getJType().getCoderDescriptor().getCoderInstanceName(); }}, struct.fields))); out.format("\t\t@Override protected %1$s newInstance(%2$s runtime){ return new %1$s(runtime); }\n", struct.name, JObjCRuntime.class.getCanonicalName()); out.println("\t};"); out.println(); out.println("\t" + struct.name + "(final " + JObjCRuntime.class.getCanonicalName() + " runtime){"); out.println("\t\tsuper(runtime, SIZEOF);"); out.println("\t}"); out.println(); out.println("\tpublic " + struct.name + "(final " + JObjCRuntime.class.getCanonicalName() + " runtime, final com.apple.jobjc.NativeBuffer buffer) {"); out.println("\t\tsuper(runtime, buffer, SIZEOF);"); out.println("\t}"); }
Example #4
Source File: StructClassFile.java From jdk8u60 with GNU General Public License v2.0 | 6 votes |
@Override public void writeBeginning(final PrintStream out) { out.println(); out.println("\tpublic static int SIZEOF = " + JObjCRuntime.class.getName() + ".IS64 ? " + ((NStruct) struct.type.type64).sizeof64() + " : " + ((NStruct) struct.type.type32).sizeof32() + ";"); out.println(); out.format("\tpublic final static %1$s getStructCoder(){ return coder; }\n", StructCoder.class.getCanonicalName()); out.format("\t@Override public final %1$s getCoder(){ return coder; }\n", StructCoder.class.getCanonicalName()); out.format("\tprivate final static %1$s coder = new %1$s(SIZEOF%2$s%3$s){\n", StructCoder.class.getCanonicalName(), (struct.fields.size() > 0 ? ",\n\t\t" : ""), Fp.join(",\n\t\t", Fp.map(new Map1<Field,String>(){ public String apply(Field a) { return a.type.getJType().getCoderDescriptor().getCoderInstanceName(); }}, struct.fields))); out.format("\t\t@Override protected %1$s newInstance(%2$s runtime){ return new %1$s(runtime); }\n", struct.name, JObjCRuntime.class.getCanonicalName()); out.println("\t};"); out.println(); out.println("\t" + struct.name + "(final " + JObjCRuntime.class.getCanonicalName() + " runtime){"); out.println("\t\tsuper(runtime, SIZEOF);"); out.println("\t}"); out.println(); out.println("\tpublic " + struct.name + "(final " + JObjCRuntime.class.getCanonicalName() + " runtime, final com.apple.jobjc.NativeBuffer buffer) {"); out.println("\t\tsuper(runtime, buffer, SIZEOF);"); out.println("\t}"); }
Example #5
Source File: StructClassFile.java From openjdk-jdk8u with GNU General Public License v2.0 | 6 votes |
@Override public void writeBeginning(final PrintStream out) { out.println(); out.println("\tpublic static int SIZEOF = " + JObjCRuntime.class.getName() + ".IS64 ? " + ((NStruct) struct.type.type64).sizeof64() + " : " + ((NStruct) struct.type.type32).sizeof32() + ";"); out.println(); out.format("\tpublic final static %1$s getStructCoder(){ return coder; }\n", StructCoder.class.getCanonicalName()); out.format("\t@Override public final %1$s getCoder(){ return coder; }\n", StructCoder.class.getCanonicalName()); out.format("\tprivate final static %1$s coder = new %1$s(SIZEOF%2$s%3$s){\n", StructCoder.class.getCanonicalName(), (struct.fields.size() > 0 ? ",\n\t\t" : ""), Fp.join(",\n\t\t", Fp.map(new Map1<Field,String>(){ public String apply(Field a) { return a.type.getJType().getCoderDescriptor().getCoderInstanceName(); }}, struct.fields))); out.format("\t\t@Override protected %1$s newInstance(%2$s runtime){ return new %1$s(runtime); }\n", struct.name, JObjCRuntime.class.getCanonicalName()); out.println("\t};"); out.println(); out.println("\t" + struct.name + "(final " + JObjCRuntime.class.getCanonicalName() + " runtime){"); out.println("\t\tsuper(runtime, SIZEOF);"); out.println("\t}"); out.println(); out.println("\tpublic " + struct.name + "(final " + JObjCRuntime.class.getCanonicalName() + " runtime, final com.apple.jobjc.NativeBuffer buffer) {"); out.println("\t\tsuper(runtime, buffer, SIZEOF);"); out.println("\t}"); }
Example #6
Source File: StructClassFile.java From jdk8u-jdk with GNU General Public License v2.0 | 6 votes |
@Override public void writeBeginning(final PrintStream out) { out.println(); out.println("\tpublic static int SIZEOF = " + JObjCRuntime.class.getName() + ".IS64 ? " + ((NStruct) struct.type.type64).sizeof64() + " : " + ((NStruct) struct.type.type32).sizeof32() + ";"); out.println(); out.format("\tpublic final static %1$s getStructCoder(){ return coder; }\n", StructCoder.class.getCanonicalName()); out.format("\t@Override public final %1$s getCoder(){ return coder; }\n", StructCoder.class.getCanonicalName()); out.format("\tprivate final static %1$s coder = new %1$s(SIZEOF%2$s%3$s){\n", StructCoder.class.getCanonicalName(), (struct.fields.size() > 0 ? ",\n\t\t" : ""), Fp.join(",\n\t\t", Fp.map(new Map1<Field,String>(){ public String apply(Field a) { return a.type.getJType().getCoderDescriptor().getCoderInstanceName(); }}, struct.fields))); out.format("\t\t@Override protected %1$s newInstance(%2$s runtime){ return new %1$s(runtime); }\n", struct.name, JObjCRuntime.class.getCanonicalName()); out.println("\t};"); out.println(); out.println("\t" + struct.name + "(final " + JObjCRuntime.class.getCanonicalName() + " runtime){"); out.println("\t\tsuper(runtime, SIZEOF);"); out.println("\t}"); out.println(); out.println("\tpublic " + struct.name + "(final " + JObjCRuntime.class.getCanonicalName() + " runtime, final com.apple.jobjc.NativeBuffer buffer) {"); out.println("\t\tsuper(runtime, buffer, SIZEOF);"); out.println("\t}"); }
Example #7
Source File: StructClassFile.java From openjdk-jdk8u-backup with GNU General Public License v2.0 | 6 votes |
@Override public void writeBeginning(final PrintStream out) { out.println(); out.println("\tpublic static int SIZEOF = " + JObjCRuntime.class.getName() + ".IS64 ? " + ((NStruct) struct.type.type64).sizeof64() + " : " + ((NStruct) struct.type.type32).sizeof32() + ";"); out.println(); out.format("\tpublic final static %1$s getStructCoder(){ return coder; }\n", StructCoder.class.getCanonicalName()); out.format("\t@Override public final %1$s getCoder(){ return coder; }\n", StructCoder.class.getCanonicalName()); out.format("\tprivate final static %1$s coder = new %1$s(SIZEOF%2$s%3$s){\n", StructCoder.class.getCanonicalName(), (struct.fields.size() > 0 ? ",\n\t\t" : ""), Fp.join(",\n\t\t", Fp.map(new Map1<Field,String>(){ public String apply(Field a) { return a.type.getJType().getCoderDescriptor().getCoderInstanceName(); }}, struct.fields))); out.format("\t\t@Override protected %1$s newInstance(%2$s runtime){ return new %1$s(runtime); }\n", struct.name, JObjCRuntime.class.getCanonicalName()); out.println("\t};"); out.println(); out.println("\t" + struct.name + "(final " + JObjCRuntime.class.getCanonicalName() + " runtime){"); out.println("\t\tsuper(runtime, SIZEOF);"); out.println("\t}"); out.println(); out.println("\tpublic " + struct.name + "(final " + JObjCRuntime.class.getCanonicalName() + " runtime, final com.apple.jobjc.NativeBuffer buffer) {"); out.println("\t\tsuper(runtime, buffer, SIZEOF);"); out.println("\t}"); }
Example #8
Source File: StructClassFile.java From jdk8u-jdk with GNU General Public License v2.0 | 6 votes |
@Override public void writeBeginning(final PrintStream out) { out.println(); out.println("\tpublic static int SIZEOF = " + JObjCRuntime.class.getName() + ".IS64 ? " + ((NStruct) struct.type.type64).sizeof64() + " : " + ((NStruct) struct.type.type32).sizeof32() + ";"); out.println(); out.format("\tpublic final static %1$s getStructCoder(){ return coder; }\n", StructCoder.class.getCanonicalName()); out.format("\t@Override public final %1$s getCoder(){ return coder; }\n", StructCoder.class.getCanonicalName()); out.format("\tprivate final static %1$s coder = new %1$s(SIZEOF%2$s%3$s){\n", StructCoder.class.getCanonicalName(), (struct.fields.size() > 0 ? ",\n\t\t" : ""), Fp.join(",\n\t\t", Fp.map(new Map1<Field,String>(){ public String apply(Field a) { return a.type.getJType().getCoderDescriptor().getCoderInstanceName(); }}, struct.fields))); out.format("\t\t@Override protected %1$s newInstance(%2$s runtime){ return new %1$s(runtime); }\n", struct.name, JObjCRuntime.class.getCanonicalName()); out.println("\t};"); out.println(); out.println("\t" + struct.name + "(final " + JObjCRuntime.class.getCanonicalName() + " runtime){"); out.println("\t\tsuper(runtime, SIZEOF);"); out.println("\t}"); out.println(); out.println("\tpublic " + struct.name + "(final " + JObjCRuntime.class.getCanonicalName() + " runtime, final com.apple.jobjc.NativeBuffer buffer) {"); out.println("\t\tsuper(runtime, buffer, SIZEOF);"); out.println("\t}"); }
Example #9
Source File: StructClassFile.java From jdk8u_jdk with GNU General Public License v2.0 | 6 votes |
@Override public void writeBeginning(final PrintStream out) { out.println(); out.println("\tpublic static int SIZEOF = " + JObjCRuntime.class.getName() + ".IS64 ? " + ((NStruct) struct.type.type64).sizeof64() + " : " + ((NStruct) struct.type.type32).sizeof32() + ";"); out.println(); out.format("\tpublic final static %1$s getStructCoder(){ return coder; }\n", StructCoder.class.getCanonicalName()); out.format("\t@Override public final %1$s getCoder(){ return coder; }\n", StructCoder.class.getCanonicalName()); out.format("\tprivate final static %1$s coder = new %1$s(SIZEOF%2$s%3$s){\n", StructCoder.class.getCanonicalName(), (struct.fields.size() > 0 ? ",\n\t\t" : ""), Fp.join(",\n\t\t", Fp.map(new Map1<Field,String>(){ public String apply(Field a) { return a.type.getJType().getCoderDescriptor().getCoderInstanceName(); }}, struct.fields))); out.format("\t\t@Override protected %1$s newInstance(%2$s runtime){ return new %1$s(runtime); }\n", struct.name, JObjCRuntime.class.getCanonicalName()); out.println("\t};"); out.println(); out.println("\t" + struct.name + "(final " + JObjCRuntime.class.getCanonicalName() + " runtime){"); out.println("\t\tsuper(runtime, SIZEOF);"); out.println("\t}"); out.println(); out.println("\tpublic " + struct.name + "(final " + JObjCRuntime.class.getCanonicalName() + " runtime, final com.apple.jobjc.NativeBuffer buffer) {"); out.println("\t\tsuper(runtime, buffer, SIZEOF);"); out.println("\t}"); }
Example #10
Source File: StructClassFile.java From hottub with GNU General Public License v2.0 | 6 votes |
@Override public void writeBeginning(final PrintStream out) { out.println(); out.println("\tpublic static int SIZEOF = " + JObjCRuntime.class.getName() + ".IS64 ? " + ((NStruct) struct.type.type64).sizeof64() + " : " + ((NStruct) struct.type.type32).sizeof32() + ";"); out.println(); out.format("\tpublic final static %1$s getStructCoder(){ return coder; }\n", StructCoder.class.getCanonicalName()); out.format("\t@Override public final %1$s getCoder(){ return coder; }\n", StructCoder.class.getCanonicalName()); out.format("\tprivate final static %1$s coder = new %1$s(SIZEOF%2$s%3$s){\n", StructCoder.class.getCanonicalName(), (struct.fields.size() > 0 ? ",\n\t\t" : ""), Fp.join(",\n\t\t", Fp.map(new Map1<Field,String>(){ public String apply(Field a) { return a.type.getJType().getCoderDescriptor().getCoderInstanceName(); }}, struct.fields))); out.format("\t\t@Override protected %1$s newInstance(%2$s runtime){ return new %1$s(runtime); }\n", struct.name, JObjCRuntime.class.getCanonicalName()); out.println("\t};"); out.println(); out.println("\t" + struct.name + "(final " + JObjCRuntime.class.getCanonicalName() + " runtime){"); out.println("\t\tsuper(runtime, SIZEOF);"); out.println("\t}"); out.println(); out.println("\tpublic " + struct.name + "(final " + JObjCRuntime.class.getCanonicalName() + " runtime, final com.apple.jobjc.NativeBuffer buffer) {"); out.println("\t\tsuper(runtime, buffer, SIZEOF);"); out.println("\t}"); }
Example #11
Source File: StructClassFile.java From openjdk-8-source with GNU General Public License v2.0 | 6 votes |
@Override public void writeBeginning(final PrintStream out) { out.println(); out.println("\tpublic static int SIZEOF = " + JObjCRuntime.class.getName() + ".IS64 ? " + ((NStruct) struct.type.type64).sizeof64() + " : " + ((NStruct) struct.type.type32).sizeof32() + ";"); out.println(); out.format("\tpublic final static %1$s getStructCoder(){ return coder; }\n", StructCoder.class.getCanonicalName()); out.format("\t@Override public final %1$s getCoder(){ return coder; }\n", StructCoder.class.getCanonicalName()); out.format("\tprivate final static %1$s coder = new %1$s(SIZEOF%2$s%3$s){\n", StructCoder.class.getCanonicalName(), (struct.fields.size() > 0 ? ",\n\t\t" : ""), Fp.join(",\n\t\t", Fp.map(new Map1<Field,String>(){ public String apply(Field a) { return a.type.getJType().getCoderDescriptor().getCoderInstanceName(); }}, struct.fields))); out.format("\t\t@Override protected %1$s newInstance(%2$s runtime){ return new %1$s(runtime); }\n", struct.name, JObjCRuntime.class.getCanonicalName()); out.println("\t};"); out.println(); out.println("\t" + struct.name + "(final " + JObjCRuntime.class.getCanonicalName() + " runtime){"); out.println("\t\tsuper(runtime, SIZEOF);"); out.println("\t}"); out.println(); out.println("\tpublic " + struct.name + "(final " + JObjCRuntime.class.getCanonicalName() + " runtime, final com.apple.jobjc.NativeBuffer buffer) {"); out.println("\t\tsuper(runtime, buffer, SIZEOF);"); out.println("\t}"); }
Example #12
Source File: StructClassFile.java From openjdk-8 with GNU General Public License v2.0 | 6 votes |
@Override public void writeBeginning(final PrintStream out) { out.println(); out.println("\tpublic static int SIZEOF = " + JObjCRuntime.class.getName() + ".IS64 ? " + ((NStruct) struct.type.type64).sizeof64() + " : " + ((NStruct) struct.type.type32).sizeof32() + ";"); out.println(); out.format("\tpublic final static %1$s getStructCoder(){ return coder; }\n", StructCoder.class.getCanonicalName()); out.format("\t@Override public final %1$s getCoder(){ return coder; }\n", StructCoder.class.getCanonicalName()); out.format("\tprivate final static %1$s coder = new %1$s(SIZEOF%2$s%3$s){\n", StructCoder.class.getCanonicalName(), (struct.fields.size() > 0 ? ",\n\t\t" : ""), Fp.join(",\n\t\t", Fp.map(new Map1<Field,String>(){ public String apply(Field a) { return a.type.getJType().getCoderDescriptor().getCoderInstanceName(); }}, struct.fields))); out.format("\t\t@Override protected %1$s newInstance(%2$s runtime){ return new %1$s(runtime); }\n", struct.name, JObjCRuntime.class.getCanonicalName()); out.println("\t};"); out.println(); out.println("\t" + struct.name + "(final " + JObjCRuntime.class.getCanonicalName() + " runtime){"); out.println("\t\tsuper(runtime, SIZEOF);"); out.println("\t}"); out.println(); out.println("\tpublic " + struct.name + "(final " + JObjCRuntime.class.getCanonicalName() + " runtime, final com.apple.jobjc.NativeBuffer buffer) {"); out.println("\t\tsuper(runtime, buffer, SIZEOF);"); out.println("\t}"); }
Example #13
Source File: Invoke.java From jdk8u-dev-jdk with GNU General Public License v2.0 | 4 votes |
static long getMsgSendFxnPtr(final Coder returnCoder) { if(returnCoder instanceof StructCoder){ StructCoder scoder = (StructCoder) returnCoder; switch(JObjCRuntime.ARCH){ case ppc: return OBJC_MSG_SEND_STRET_FXN_PTR; case i386: switch(scoder.sizeof){ case 1: case 2: case 4: case 8: return OBJC_MSG_SEND_FXN_PTR; } return OBJC_MSG_SEND_STRET_FXN_PTR; case x86_64: if(scoder.sizeof > 16) return OBJC_MSG_SEND_STRET_FXN_PTR; else return OBJC_MSG_SEND_FXN_PTR; default: throw new RuntimeException(); } } final int typeCode = returnCoder.getTypeCode(); switch(JObjCRuntime.ARCH){ case ppc: return OBJC_MSG_SEND_FXN_PTR; case i386: switch(typeCode) { case Coder.FFI_FLOAT: case Coder.FFI_DOUBLE: case Coder.FFI_LONGDOUBLE: return OBJC_MSG_SEND_FPRET_FXN_PTR; } return OBJC_MSG_SEND_FXN_PTR; case x86_64: if(typeCode == Coder.FFI_LONGDOUBLE) return OBJC_MSG_SEND_FPRET_FXN_PTR; return OBJC_MSG_SEND_FXN_PTR; default: throw new RuntimeException(); } }
Example #14
Source File: Invoke.java From jdk8u-jdk with GNU General Public License v2.0 | 4 votes |
static long getMsgSendFxnPtr(final Coder returnCoder) { if(returnCoder instanceof StructCoder){ StructCoder scoder = (StructCoder) returnCoder; switch(JObjCRuntime.ARCH){ case ppc: return OBJC_MSG_SEND_STRET_FXN_PTR; case i386: switch(scoder.sizeof){ case 1: case 2: case 4: case 8: return OBJC_MSG_SEND_FXN_PTR; } return OBJC_MSG_SEND_STRET_FXN_PTR; case x86_64: if(scoder.sizeof > 16) return OBJC_MSG_SEND_STRET_FXN_PTR; else return OBJC_MSG_SEND_FXN_PTR; default: throw new RuntimeException(); } } final int typeCode = returnCoder.getTypeCode(); switch(JObjCRuntime.ARCH){ case ppc: return OBJC_MSG_SEND_FXN_PTR; case i386: switch(typeCode) { case Coder.FFI_FLOAT: case Coder.FFI_DOUBLE: case Coder.FFI_LONGDOUBLE: return OBJC_MSG_SEND_FPRET_FXN_PTR; } return OBJC_MSG_SEND_FXN_PTR; case x86_64: if(typeCode == Coder.FFI_LONGDOUBLE) return OBJC_MSG_SEND_FPRET_FXN_PTR; return OBJC_MSG_SEND_FXN_PTR; default: throw new RuntimeException(); } }
Example #15
Source File: Invoke.java From jdk8u_jdk with GNU General Public License v2.0 | 4 votes |
static long getMsgSendFxnPtr(final Coder returnCoder) { if(returnCoder instanceof StructCoder){ StructCoder scoder = (StructCoder) returnCoder; switch(JObjCRuntime.ARCH){ case ppc: return OBJC_MSG_SEND_STRET_FXN_PTR; case i386: switch(scoder.sizeof){ case 1: case 2: case 4: case 8: return OBJC_MSG_SEND_FXN_PTR; } return OBJC_MSG_SEND_STRET_FXN_PTR; case x86_64: if(scoder.sizeof > 16) return OBJC_MSG_SEND_STRET_FXN_PTR; else return OBJC_MSG_SEND_FXN_PTR; default: throw new RuntimeException(); } } final int typeCode = returnCoder.getTypeCode(); switch(JObjCRuntime.ARCH){ case ppc: return OBJC_MSG_SEND_FXN_PTR; case i386: switch(typeCode) { case Coder.FFI_FLOAT: case Coder.FFI_DOUBLE: case Coder.FFI_LONGDOUBLE: return OBJC_MSG_SEND_FPRET_FXN_PTR; } return OBJC_MSG_SEND_FXN_PTR; case x86_64: if(typeCode == Coder.FFI_LONGDOUBLE) return OBJC_MSG_SEND_FPRET_FXN_PTR; return OBJC_MSG_SEND_FXN_PTR; default: throw new RuntimeException(); } }
Example #16
Source File: Invoke.java From openjdk-8 with GNU General Public License v2.0 | 4 votes |
static long getMsgSendFxnPtr(final Coder returnCoder) { if(returnCoder instanceof StructCoder){ StructCoder scoder = (StructCoder) returnCoder; switch(JObjCRuntime.ARCH){ case ppc: return OBJC_MSG_SEND_STRET_FXN_PTR; case i386: switch(scoder.sizeof){ case 1: case 2: case 4: case 8: return OBJC_MSG_SEND_FXN_PTR; } return OBJC_MSG_SEND_STRET_FXN_PTR; case x86_64: if(scoder.sizeof > 16) return OBJC_MSG_SEND_STRET_FXN_PTR; else return OBJC_MSG_SEND_FXN_PTR; default: throw new RuntimeException(); } } final int typeCode = returnCoder.getTypeCode(); switch(JObjCRuntime.ARCH){ case ppc: return OBJC_MSG_SEND_FXN_PTR; case i386: switch(typeCode) { case Coder.FFI_FLOAT: case Coder.FFI_DOUBLE: case Coder.FFI_LONGDOUBLE: return OBJC_MSG_SEND_FPRET_FXN_PTR; } return OBJC_MSG_SEND_FXN_PTR; case x86_64: if(typeCode == Coder.FFI_LONGDOUBLE) return OBJC_MSG_SEND_FPRET_FXN_PTR; return OBJC_MSG_SEND_FXN_PTR; default: throw new RuntimeException(); } }
Example #17
Source File: Invoke.java From openjdk-8-source with GNU General Public License v2.0 | 4 votes |
static long getMsgSendFxnPtr(final Coder returnCoder) { if(returnCoder instanceof StructCoder){ StructCoder scoder = (StructCoder) returnCoder; switch(JObjCRuntime.ARCH){ case ppc: return OBJC_MSG_SEND_STRET_FXN_PTR; case i386: switch(scoder.sizeof){ case 1: case 2: case 4: case 8: return OBJC_MSG_SEND_FXN_PTR; } return OBJC_MSG_SEND_STRET_FXN_PTR; case x86_64: if(scoder.sizeof > 16) return OBJC_MSG_SEND_STRET_FXN_PTR; else return OBJC_MSG_SEND_FXN_PTR; default: throw new RuntimeException(); } } final int typeCode = returnCoder.getTypeCode(); switch(JObjCRuntime.ARCH){ case ppc: return OBJC_MSG_SEND_FXN_PTR; case i386: switch(typeCode) { case Coder.FFI_FLOAT: case Coder.FFI_DOUBLE: case Coder.FFI_LONGDOUBLE: return OBJC_MSG_SEND_FPRET_FXN_PTR; } return OBJC_MSG_SEND_FXN_PTR; case x86_64: if(typeCode == Coder.FFI_LONGDOUBLE) return OBJC_MSG_SEND_FPRET_FXN_PTR; return OBJC_MSG_SEND_FXN_PTR; default: throw new RuntimeException(); } }
Example #18
Source File: Invoke.java From hottub with GNU General Public License v2.0 | 4 votes |
static long getMsgSendFxnPtr(final Coder returnCoder) { if(returnCoder instanceof StructCoder){ StructCoder scoder = (StructCoder) returnCoder; switch(JObjCRuntime.ARCH){ case ppc: return OBJC_MSG_SEND_STRET_FXN_PTR; case i386: switch(scoder.sizeof){ case 1: case 2: case 4: case 8: return OBJC_MSG_SEND_FXN_PTR; } return OBJC_MSG_SEND_STRET_FXN_PTR; case x86_64: if(scoder.sizeof > 16) return OBJC_MSG_SEND_STRET_FXN_PTR; else return OBJC_MSG_SEND_FXN_PTR; default: throw new RuntimeException(); } } final int typeCode = returnCoder.getTypeCode(); switch(JObjCRuntime.ARCH){ case ppc: return OBJC_MSG_SEND_FXN_PTR; case i386: switch(typeCode) { case Coder.FFI_FLOAT: case Coder.FFI_DOUBLE: case Coder.FFI_LONGDOUBLE: return OBJC_MSG_SEND_FPRET_FXN_PTR; } return OBJC_MSG_SEND_FXN_PTR; case x86_64: if(typeCode == Coder.FFI_LONGDOUBLE) return OBJC_MSG_SEND_FPRET_FXN_PTR; return OBJC_MSG_SEND_FXN_PTR; default: throw new RuntimeException(); } }
Example #19
Source File: Invoke.java From jdk8u-jdk with GNU General Public License v2.0 | 4 votes |
static long getMsgSendFxnPtr(final Coder returnCoder) { if(returnCoder instanceof StructCoder){ StructCoder scoder = (StructCoder) returnCoder; switch(JObjCRuntime.ARCH){ case ppc: return OBJC_MSG_SEND_STRET_FXN_PTR; case i386: switch(scoder.sizeof){ case 1: case 2: case 4: case 8: return OBJC_MSG_SEND_FXN_PTR; } return OBJC_MSG_SEND_STRET_FXN_PTR; case x86_64: if(scoder.sizeof > 16) return OBJC_MSG_SEND_STRET_FXN_PTR; else return OBJC_MSG_SEND_FXN_PTR; default: throw new RuntimeException(); } } final int typeCode = returnCoder.getTypeCode(); switch(JObjCRuntime.ARCH){ case ppc: return OBJC_MSG_SEND_FXN_PTR; case i386: switch(typeCode) { case Coder.FFI_FLOAT: case Coder.FFI_DOUBLE: case Coder.FFI_LONGDOUBLE: return OBJC_MSG_SEND_FPRET_FXN_PTR; } return OBJC_MSG_SEND_FXN_PTR; case x86_64: if(typeCode == Coder.FFI_LONGDOUBLE) return OBJC_MSG_SEND_FPRET_FXN_PTR; return OBJC_MSG_SEND_FXN_PTR; default: throw new RuntimeException(); } }
Example #20
Source File: Invoke.java From openjdk-jdk8u-backup with GNU General Public License v2.0 | 4 votes |
static long getMsgSendFxnPtr(final Coder returnCoder) { if(returnCoder instanceof StructCoder){ StructCoder scoder = (StructCoder) returnCoder; switch(JObjCRuntime.ARCH){ case ppc: return OBJC_MSG_SEND_STRET_FXN_PTR; case i386: switch(scoder.sizeof){ case 1: case 2: case 4: case 8: return OBJC_MSG_SEND_FXN_PTR; } return OBJC_MSG_SEND_STRET_FXN_PTR; case x86_64: if(scoder.sizeof > 16) return OBJC_MSG_SEND_STRET_FXN_PTR; else return OBJC_MSG_SEND_FXN_PTR; default: throw new RuntimeException(); } } final int typeCode = returnCoder.getTypeCode(); switch(JObjCRuntime.ARCH){ case ppc: return OBJC_MSG_SEND_FXN_PTR; case i386: switch(typeCode) { case Coder.FFI_FLOAT: case Coder.FFI_DOUBLE: case Coder.FFI_LONGDOUBLE: return OBJC_MSG_SEND_FPRET_FXN_PTR; } return OBJC_MSG_SEND_FXN_PTR; case x86_64: if(typeCode == Coder.FFI_LONGDOUBLE) return OBJC_MSG_SEND_FPRET_FXN_PTR; return OBJC_MSG_SEND_FXN_PTR; default: throw new RuntimeException(); } }
Example #21
Source File: Invoke.java From openjdk-jdk8u with GNU General Public License v2.0 | 4 votes |
static long getMsgSendFxnPtr(final Coder returnCoder) { if(returnCoder instanceof StructCoder){ StructCoder scoder = (StructCoder) returnCoder; switch(JObjCRuntime.ARCH){ case ppc: return OBJC_MSG_SEND_STRET_FXN_PTR; case i386: switch(scoder.sizeof){ case 1: case 2: case 4: case 8: return OBJC_MSG_SEND_FXN_PTR; } return OBJC_MSG_SEND_STRET_FXN_PTR; case x86_64: if(scoder.sizeof > 16) return OBJC_MSG_SEND_STRET_FXN_PTR; else return OBJC_MSG_SEND_FXN_PTR; default: throw new RuntimeException(); } } final int typeCode = returnCoder.getTypeCode(); switch(JObjCRuntime.ARCH){ case ppc: return OBJC_MSG_SEND_FXN_PTR; case i386: switch(typeCode) { case Coder.FFI_FLOAT: case Coder.FFI_DOUBLE: case Coder.FFI_LONGDOUBLE: return OBJC_MSG_SEND_FPRET_FXN_PTR; } return OBJC_MSG_SEND_FXN_PTR; case x86_64: if(typeCode == Coder.FFI_LONGDOUBLE) return OBJC_MSG_SEND_FPRET_FXN_PTR; return OBJC_MSG_SEND_FXN_PTR; default: throw new RuntimeException(); } }
Example #22
Source File: Invoke.java From jdk8u60 with GNU General Public License v2.0 | 4 votes |
static long getMsgSendFxnPtr(final Coder returnCoder) { if(returnCoder instanceof StructCoder){ StructCoder scoder = (StructCoder) returnCoder; switch(JObjCRuntime.ARCH){ case ppc: return OBJC_MSG_SEND_STRET_FXN_PTR; case i386: switch(scoder.sizeof){ case 1: case 2: case 4: case 8: return OBJC_MSG_SEND_FXN_PTR; } return OBJC_MSG_SEND_STRET_FXN_PTR; case x86_64: if(scoder.sizeof > 16) return OBJC_MSG_SEND_STRET_FXN_PTR; else return OBJC_MSG_SEND_FXN_PTR; default: throw new RuntimeException(); } } final int typeCode = returnCoder.getTypeCode(); switch(JObjCRuntime.ARCH){ case ppc: return OBJC_MSG_SEND_FXN_PTR; case i386: switch(typeCode) { case Coder.FFI_FLOAT: case Coder.FFI_DOUBLE: case Coder.FFI_LONGDOUBLE: return OBJC_MSG_SEND_FPRET_FXN_PTR; } return OBJC_MSG_SEND_FXN_PTR; case x86_64: if(typeCode == Coder.FFI_LONGDOUBLE) return OBJC_MSG_SEND_FPRET_FXN_PTR; return OBJC_MSG_SEND_FXN_PTR; default: throw new RuntimeException(); } }
Example #23
Source File: Invoke.java From TencentKona-8 with GNU General Public License v2.0 | 4 votes |
static long getMsgSendFxnPtr(final Coder returnCoder) { if(returnCoder instanceof StructCoder){ StructCoder scoder = (StructCoder) returnCoder; switch(JObjCRuntime.ARCH){ case ppc: return OBJC_MSG_SEND_STRET_FXN_PTR; case i386: switch(scoder.sizeof){ case 1: case 2: case 4: case 8: return OBJC_MSG_SEND_FXN_PTR; } return OBJC_MSG_SEND_STRET_FXN_PTR; case x86_64: if(scoder.sizeof > 16) return OBJC_MSG_SEND_STRET_FXN_PTR; else return OBJC_MSG_SEND_FXN_PTR; default: throw new RuntimeException(); } } final int typeCode = returnCoder.getTypeCode(); switch(JObjCRuntime.ARCH){ case ppc: return OBJC_MSG_SEND_FXN_PTR; case i386: switch(typeCode) { case Coder.FFI_FLOAT: case Coder.FFI_DOUBLE: case Coder.FFI_LONGDOUBLE: return OBJC_MSG_SEND_FPRET_FXN_PTR; } return OBJC_MSG_SEND_FXN_PTR; case x86_64: if(typeCode == Coder.FFI_LONGDOUBLE) return OBJC_MSG_SEND_FPRET_FXN_PTR; return OBJC_MSG_SEND_FXN_PTR; default: throw new RuntimeException(); } }
Example #24
Source File: Invoke.java From dragonwell8_jdk with GNU General Public License v2.0 | 4 votes |
static long getMsgSendFxnPtr(final Coder returnCoder) { if(returnCoder instanceof StructCoder){ StructCoder scoder = (StructCoder) returnCoder; switch(JObjCRuntime.ARCH){ case ppc: return OBJC_MSG_SEND_STRET_FXN_PTR; case i386: switch(scoder.sizeof){ case 1: case 2: case 4: case 8: return OBJC_MSG_SEND_FXN_PTR; } return OBJC_MSG_SEND_STRET_FXN_PTR; case x86_64: if(scoder.sizeof > 16) return OBJC_MSG_SEND_STRET_FXN_PTR; else return OBJC_MSG_SEND_FXN_PTR; default: throw new RuntimeException(); } } final int typeCode = returnCoder.getTypeCode(); switch(JObjCRuntime.ARCH){ case ppc: return OBJC_MSG_SEND_FXN_PTR; case i386: switch(typeCode) { case Coder.FFI_FLOAT: case Coder.FFI_DOUBLE: case Coder.FFI_LONGDOUBLE: return OBJC_MSG_SEND_FPRET_FXN_PTR; } return OBJC_MSG_SEND_FXN_PTR; case x86_64: if(typeCode == Coder.FFI_LONGDOUBLE) return OBJC_MSG_SEND_FPRET_FXN_PTR; return OBJC_MSG_SEND_FXN_PTR; default: throw new RuntimeException(); } }