diff options
| author | Paul Eggert | 2016-12-23 21:38:59 -0800 |
|---|---|---|
| committer | Paul Eggert | 2016-12-23 21:46:53 -0800 |
| commit | e36a3882c338765a9ddfebfc160e5a298933f233 (patch) | |
| tree | 2401cec6ab1dd50136946d1369cbf082aad90355 /src/bytecode.c | |
| parent | a815e5f19581344af5e143636039064a7fbe83ed (diff) | |
| download | emacs-e36a3882c338765a9ddfebfc160e5a298933f233.tar.gz emacs-e36a3882c338765a9ddfebfc160e5a298933f233.zip | |
Simplify exec_byte_code via moving decls etc.
* src/bytecode.c (exec_byte_code): Simplify, mostly by moving
initializers into decls, and by omitting some unnecessary changes
to ‘top’.
Diffstat (limited to 'src/bytecode.c')
| -rw-r--r-- | src/bytecode.c | 40 |
1 files changed, 15 insertions, 25 deletions
diff --git a/src/bytecode.c b/src/bytecode.c index 51546ca474d..d484dbb25c6 100644 --- a/src/bytecode.c +++ b/src/bytecode.c | |||
| @@ -508,9 +508,8 @@ exec_byte_code (Lisp_Object bytestr, Lisp_Object vector, Lisp_Object maxdepth, | |||
| 508 | 508 | ||
| 509 | CASE (Bgotoifnil): | 509 | CASE (Bgotoifnil): |
| 510 | { | 510 | { |
| 511 | Lisp_Object v1; | 511 | Lisp_Object v1 = POP; |
| 512 | op = FETCH2; | 512 | op = FETCH2; |
| 513 | v1 = POP; | ||
| 514 | if (NILP (v1)) | 513 | if (NILP (v1)) |
| 515 | goto op_branch; | 514 | goto op_branch; |
| 516 | NEXT; | 515 | NEXT; |
| @@ -686,13 +685,10 @@ exec_byte_code (Lisp_Object bytestr, Lisp_Object vector, Lisp_Object maxdepth, | |||
| 686 | NEXT; | 685 | NEXT; |
| 687 | 686 | ||
| 688 | CASE (Bgotoifnonnil): | 687 | CASE (Bgotoifnonnil): |
| 689 | { | 688 | op = FETCH2; |
| 690 | op = FETCH2; | 689 | if (!NILP (POP)) |
| 691 | Lisp_Object v1 = POP; | 690 | goto op_branch; |
| 692 | if (!NILP (v1)) | 691 | NEXT; |
| 693 | goto op_branch; | ||
| 694 | NEXT; | ||
| 695 | } | ||
| 696 | 692 | ||
| 697 | CASE (Bgotoifnilelsepop): | 693 | CASE (Bgotoifnilelsepop): |
| 698 | op = FETCH2; | 694 | op = FETCH2; |
| @@ -713,22 +709,16 @@ exec_byte_code (Lisp_Object bytestr, Lisp_Object vector, Lisp_Object maxdepth, | |||
| 713 | goto op_relative_branch; | 709 | goto op_relative_branch; |
| 714 | 710 | ||
| 715 | CASE (BRgotoifnil): | 711 | CASE (BRgotoifnil): |
| 716 | { | 712 | op = FETCH - 128; |
| 717 | Lisp_Object v1 = POP; | 713 | if (NILP (POP)) |
| 718 | op = FETCH - 128; | 714 | goto op_relative_branch; |
| 719 | if (NILP (v1)) | 715 | NEXT; |
| 720 | goto op_relative_branch; | ||
| 721 | NEXT; | ||
| 722 | } | ||
| 723 | 716 | ||
| 724 | CASE (BRgotoifnonnil): | 717 | CASE (BRgotoifnonnil): |
| 725 | { | 718 | op = FETCH - 128; |
| 726 | Lisp_Object v1 = POP; | 719 | if (!NILP (POP)) |
| 727 | op = FETCH - 128; | 720 | goto op_relative_branch; |
| 728 | if (!NILP (v1)) | 721 | NEXT; |
| 729 | goto op_relative_branch; | ||
| 730 | NEXT; | ||
| 731 | } | ||
| 732 | 722 | ||
| 733 | CASE (BRgotoifnilelsepop): | 723 | CASE (BRgotoifnilelsepop): |
| 734 | op = FETCH - 128; | 724 | op = FETCH - 128; |
| @@ -1248,9 +1238,9 @@ exec_byte_code (Lisp_Object bytestr, Lisp_Object vector, Lisp_Object maxdepth, | |||
| 1248 | 1238 | ||
| 1249 | CASE (Bdowncase): | 1239 | CASE (Bdowncase): |
| 1250 | TOP = Fdowncase (TOP); | 1240 | TOP = Fdowncase (TOP); |
| 1251 | NEXT; | 1241 | NEXT; |
| 1252 | 1242 | ||
| 1253 | CASE (Bstringeqlsign): | 1243 | CASE (Bstringeqlsign): |
| 1254 | { | 1244 | { |
| 1255 | Lisp_Object v1 = POP; | 1245 | Lisp_Object v1 = POP; |
| 1256 | TOP = Fstring_equal (TOP, v1); | 1246 | TOP = Fstring_equal (TOP, v1); |