提交 405edfdc 编写于 作者: A Andy Polyakov

vpaes-x86.pl: portability fix.

PR: 2657
上级 3c0ff9f9
...@@ -762,7 +762,7 @@ $k_dsbo=0x2c0; # decryption sbox final output ...@@ -762,7 +762,7 @@ $k_dsbo=0x2c0; # decryption sbox final output
&mov ($magic,0x30); &mov ($magic,0x30);
&mov ($out,0); &mov ($out,0);
&lea ($const,&DWP(&label("_vpaes_consts")."+0x30-".&label("pic_point"))); &mov ($const,&label("_vpaes_consts")."+0x30-".&label("pic_point"));
&call ("_vpaes_schedule_core"); &call ("_vpaes_schedule_core");
&set_label("pic_point"); &set_label("pic_point");
...@@ -792,7 +792,7 @@ $k_dsbo=0x2c0; # decryption sbox final output ...@@ -792,7 +792,7 @@ $k_dsbo=0x2c0; # decryption sbox final output
&and ($magic,32); &and ($magic,32);
&xor ($magic,32); # nbist==192?0:32; &xor ($magic,32); # nbist==192?0:32;
&lea ($const,&DWP(&label("_vpaes_consts")."+0x30-".&label("pic_point"))); &mov ($const,&label("_vpaes_consts")."+0x30-".&label("pic_point"));
&call ("_vpaes_schedule_core"); &call ("_vpaes_schedule_core");
&set_label("pic_point"); &set_label("pic_point");
...@@ -801,7 +801,7 @@ $k_dsbo=0x2c0; # decryption sbox final output ...@@ -801,7 +801,7 @@ $k_dsbo=0x2c0; # decryption sbox final output
&function_end("${PREFIX}_set_decrypt_key"); &function_end("${PREFIX}_set_decrypt_key");
&function_begin("${PREFIX}_encrypt"); &function_begin("${PREFIX}_encrypt");
&lea ($const,&DWP(&label("_vpaes_consts")."+0x30-".&label("pic_point"))); &mov ($const,&label("_vpaes_consts")."+0x30-".&label("pic_point"));
&call ("_vpaes_preheat"); &call ("_vpaes_preheat");
&set_label("pic_point"); &set_label("pic_point");
&mov ($inp,&wparam(0)); # inp &mov ($inp,&wparam(0)); # inp
...@@ -820,7 +820,7 @@ $k_dsbo=0x2c0; # decryption sbox final output ...@@ -820,7 +820,7 @@ $k_dsbo=0x2c0; # decryption sbox final output
&function_end("${PREFIX}_encrypt"); &function_end("${PREFIX}_encrypt");
&function_begin("${PREFIX}_decrypt"); &function_begin("${PREFIX}_decrypt");
&lea ($const,&DWP(&label("_vpaes_consts")."+0x30-".&label("pic_point"))); &mov ($const,&label("_vpaes_consts")."+0x30-".&label("pic_point"));
&call ("_vpaes_preheat"); &call ("_vpaes_preheat");
&set_label("pic_point"); &set_label("pic_point");
&mov ($inp,&wparam(0)); # inp &mov ($inp,&wparam(0)); # inp
...@@ -858,7 +858,7 @@ $k_dsbo=0x2c0; # decryption sbox final output ...@@ -858,7 +858,7 @@ $k_dsbo=0x2c0; # decryption sbox final output
&mov (&DWP(8,"esp"),$const); # save ivp &mov (&DWP(8,"esp"),$const); # save ivp
&mov ($out,$round); # $out works as $len &mov ($out,$round); # $out works as $len
&lea ($const,&DWP(&label("_vpaes_consts")."+0x30-".&label("pic_point"))); &mov ($const,&label("_vpaes_consts")."+0x30-".&label("pic_point"));
&call ("_vpaes_preheat"); &call ("_vpaes_preheat");
&set_label("pic_point"); &set_label("pic_point");
&cmp ($magic,0); &cmp ($magic,0);
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册