Lines Matching refs:code
28 * Arch-specific code for manipulating GL API entrypoints (dispatch stubs).
99 GLubyte * const code = (GLubyte *) u_execmem_alloc(DISPATCH_FUNCTION_SIZE);
102 if ( code != NULL ) {
103 (void) memcpy(code, template_func, DISPATCH_FUNCTION_SIZE);
104 fill_in_entrypoint_offset( (_glapi_proc) code, functionOffset );
107 return (_glapi_proc) code;
118 GLubyte * const code = (GLubyte *) entrypoint;
120 *((unsigned int *)(code + 8)) = 4 * offset;
147 unsigned int *code = &__glapi_sparc_tls_stub;
150 code[0] = template[0] | (dispatch >> 10);
151 code[1] = template[1];
152 __glapi_sparc_icache_flush(&code[0]);
153 code[2] = template[2] | (dispatch & 0x3ff);
154 code[3] = template[3];
155 __glapi_sparc_icache_flush(&code[2]);
156 code[4] = template[4];
157 code[5] = template[5];
158 __glapi_sparc_icache_flush(&code[4]);
159 code[6] = template[6];
160 __glapi_sparc_icache_flush(&code[6]);
175 unsigned int *code = (unsigned int *) u_execmem_alloc(sizeof(template));
176 if (code) {
177 code[0] = template[0] | (functionOffset & 0x3fffff);
178 code[1] = template[1];
179 __glapi_sparc_icache_flush(&code[0]);
180 code[2] = template[2] |
181 (((call_dest - ((unsigned long) &code[2]))
183 code[3] = template[3];
184 __glapi_sparc_icache_flush(&code[2]);
186 return (_glapi_proc) code;
193 unsigned int *code = (unsigned int *) entrypoint;
195 code[0] &= ~0x3fffff;
196 code[0] |= (offset * sizeof(void *)) & 0x3fffff;
197 __glapi_sparc_icache_flush(&code[0]);