Uploaded image for project: 'Embedded Software & Tools'
  1. Embedded Software & Tools
  2. EXT_EP-8872

When shift counts are higher than 32, compiler sometimes optimizes to an incorrect shift count

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Fixed
    • Icon: Medium Medium
    • Code Generation Tools
    • CODEGEN-4638
    • Hide
      ARM_18.1.0.LTS
      MSP430_18.1.0.LTS
      MSP430_18.9.0.STS
      C6000_8.2.0
      ARM_16.9.0.LTS
      ARM_18.9.0.STS
      C6000_8.1.0B1
      PRU_2.2.0
      MSP430_16.9.0.LTS
      Show
      ARM_18.1.0.LTS MSP430_18.1.0.LTS MSP430_18.9.0.STS C6000_8.2.0 ARM_16.9.0.LTS ARM_18.9.0.STS C6000_8.1.0B1 PRU_2.2.0 MSP430_16.9.0.LTS
    • Hide
      MSP430_18.9.0.STS
      ARM_18.9.0.STS
      MSP430_16.9.8.LTS
      ARM_18.1.2.LTS
      C6000_8.2.4
      C6000_8.1.7
      PRU_2.3.0
      ARM_16.9.8.LTS
      MSP430_18.1.2.LTS
      Show
      MSP430_18.9.0.STS ARM_18.9.0.STS MSP430_16.9.8.LTS ARM_18.1.2.LTS C6000_8.2.4 C6000_8.1.7 PRU_2.3.0 ARM_16.9.8.LTS MSP430_18.1.2.LTS
    • Hide
      Turn off optimization by using optimization level off.
      Otherwise, avoid a left-shift by a constant as an operand of the listed operations. However, compiler optimizations could interfere with this. Try keeping the shift count in a global variable instead of as a literal, or computing the shift separately into a variable (a global or volatile local) and doing the |, +, etc, on the variable.
      Show
      Turn off optimization by using optimization level off. Otherwise, avoid a left-shift by a constant as an operand of the listed operations. However, compiler optimizations could interfere with this. Try keeping the shift count in a global variable instead of as a literal, or computing the shift separately into a variable (a global or volatile local) and doing the |, +, etc, on the variable.
    • Left shifts by 32 or more, as an operand of +, -, &, |, or ^, (eg, ((X<<56) | (Y<<48))) may produce incorrect results.

      When shift counts are higher than 32, compiler sometimes optimizes to an incorrect shift count

            syncuser TI User
            syncuser TI User
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

              Created:
              Updated:
              Resolved: