File tree Expand file tree Collapse file tree 1 file changed +4
-4
lines changed
Expand file tree Collapse file tree 1 file changed +4
-4
lines changed Original file line number Diff line number Diff line change @@ -117,7 +117,7 @@ void ppc_cpu_run()
117117// return;
118118 while (true ) {
119119 gCPU .npc = gCPU .pc +4 ;
120- if ((gCPU .pc & ~0xfff ) == gCPU .effective_code_page ) {
120+ if ((gCPU .pc & ~0xfff ) == gCPU .effective_code_page ) [[likely]] {
121121 opc = ppc_word_from_BE (*((uint32*)(&gCPU .physical_code_page [gCPU .pc & 0xfff ])));
122122 // ppc_debug_hook();
123123 } else {
@@ -136,14 +136,14 @@ void ppc_cpu_run()
136136 ppc_exec_opc (opc);
137137 ops++;
138138 gCPU .ptb ++;
139- if (gCPU .pdec == 0 ) {
139+ if (gCPU .pdec == 0 ) [[unlikely]] {
140140 gCPU .exception_pending = true ;
141141 gCPU .dec_exception = true ;
142142 gCPU .pdec =0xffffffff *TB_TO_PTB_FACTOR;
143143 } else {
144144 gCPU .pdec --;
145145 }
146- if ((ops & 0x3ffff )==0 ) {
146+ if ((ops & 0x3ffff )==0 ) [[unlikely]] {
147147#ifdef EMSCRIPTEN
148148 sys_gui_cpu_ops_hook (ops);
149149#endif
@@ -191,7 +191,7 @@ void ppc_cpu_run()
191191
192192 gCPU .pc = gCPU .npc ;
193193
194- if (gCPU .exception_pending ) {
194+ if (gCPU .exception_pending ) [[unlikely]] {
195195 if (gCPU .stop_exception ) {
196196 gCPU .stop_exception = false ;
197197 if (!gCPU .dec_exception && !gCPU .ext_exception ) gCPU .exception_pending = false ;
You can’t perform that action at this time.
0 commit comments