Syntax coloring
-
I think, there is a problem with syntax coloring for < pre lang="asm" > tag. I've noticed it on my post[^]. Some register names were colored while others not and some instructions also. I've changed it by assigning "cpp" (instead of "asm") to lang attribute in the post so that it appears more acceptable. That is not wholly assembly code already. As a suggestion: Nested "< pre >" tags might be a solution for inline assembly code (to have "asm" coloring within "cpp" syntax coloring). To generate the problem:
push esi push edi push ebx lea esi, x lea edi, y lea edx, b //stage one mov eax, 4 mov ebx, eax ; mov ebx, 1st dim size
_loop_00:
mov ecx, eax ; mov ecx, 2nd dim size
_loop_01:
movd mm0, [edx]
movd mm1, [esi]
paddd mm0, mm1
; psraw mm0, 6 ; // stage two
movd [edi], mm0
add esi, eax
add edi, eax
loop _loop_01
add edx, eax
dec ebx
jnz _loop_00
//stage two
// ???
pop ebx
pop edi
pop esi -
I think, there is a problem with syntax coloring for < pre lang="asm" > tag. I've noticed it on my post[^]. Some register names were colored while others not and some instructions also. I've changed it by assigning "cpp" (instead of "asm") to lang attribute in the post so that it appears more acceptable. That is not wholly assembly code already. As a suggestion: Nested "< pre >" tags might be a solution for inline assembly code (to have "asm" coloring within "cpp" syntax coloring). To generate the problem:
push esi push edi push ebx lea esi, x lea edi, y lea edx, b //stage one mov eax, 4 mov ebx, eax ; mov ebx, 1st dim size
_loop_00:
mov ecx, eax ; mov ecx, 2nd dim size
_loop_01:
movd mm0, [edx]
movd mm1, [esi]
paddd mm0, mm1
; psraw mm0, 6 ; // stage two
movd [edi], mm0
add esi, eax
add edi, eax
loop _loop_01
add edx, eax
dec ebx
jnz _loop_00
//stage two
// ???
pop ebx
pop edi
pop esiJust a matter of updating the colourisation tokens. Easily fixed.
cheers, Chris Maunder The Code Project | Co-founder Microsoft C++ MVP