Ignore:
Timestamp:
Dec 28, 2011, 8:37:13 PM (8 years ago)
Author:
gb
Message:

Define another 3-register-argument UUO ('uuo_error_array_axis_bounds');
use it to report array bounds errors for multidimensional array access
(incorporating the axis/dimension in the UUO and therefore the error
message.)

Location:
trunk/source/compiler/ARM
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • trunk/source/compiler/ARM/arm-asm.lisp

    r15130 r15158  
    320320     #x07f700ff
    321321     #x0fff00ff
    322      (:prefer-separate-cond))     
     322     (:prefer-separate-cond))
     323   (define-arm-instruction uuo-error-array-axis-bounds (:uuoC :uuoB :uuoA)
     324     #x07f000f5
     325     #x0ff000ff
     326     (:prefer-separate-cond))
    323327   ;; Kernel services.
    324328   (define-arm-instruction uuo-kernel-service (:uuo-unary)
  • trunk/source/compiler/ARM/arm-vinsns.lisp

    r15134 r15158  
    482482  (cmp i dim)
    483483  (blo :ok1)
    484   (uuo-error-array-bounds  i header)
     484  (mov dim (:$ 0))
     485  (uuo-error-array-axis-bounds  i dim header)
    485486  :ok1
    486487  (ldr dim (:@ header (:$ (+ arm::misc-data-offset (* 4 (1+ arm::arrayH.dim0-cell))))))
    487488  (cmp j dim)
    488489  (blo :ok2)
    489   (uuo-error-array-bounds  j header)
     490  (mov dim (:$ arm::fixnumone))
     491  (uuo-error-array-axis-bounds j dim header)
    490492  :ok2
    491493  (mov dim (:asr dim (:$ arm::fixnumshift))))
     
    500502  (cmp i dim1)
    501503  (blo :ok1)
    502   (uuo-error-array-bounds  i header)
     504  (mov dim1 (:$ 0))
     505  (uuo-error-array-axis-bounds  i dim1  header)
    503506  :ok1
    504507  (ldr dim1 (:@ header (:$ (+ arm::misc-data-offset (* 4 (1+ arm::arrayH.dim0-cell))))))
    505508  (cmp j dim1)
    506509  (blo :ok2)
    507   (uuo-error-array-bounds  i header)
     510  (mov dim1 (:$ arm::fixnumone))
     511  (uuo-error-array-axis-bounds  i dim1 header)
    508512  :ok2
    509513  (ldr dim2 (:@ header (:$ (+ arm::misc-data-offset (* 4 (+ 2 arm::arrayH.dim0-cell))))))
    510514  (cmp k dim2)
    511515  (blo :ok3)
    512   (uuo-error-array-bounds  i header)
     516  (mov dim2 (:$ (ash 2 arm::fixnumshift)))
     517  (uuo-error-array-axis-bounds  i dim2 header)
    513518  :ok3
    514519  (mov dim1 (:asr dim1 (:$ arm::fixnumshift)))
Note: See TracChangeset for help on using the changeset viewer.