Other Parts Discussed in Thread: TMS320F28075, CONTROLSUITE
HI all,
I am using TMS320F28075. This device is being operated at 120MHz clock.
I am executing this single line of code on adc results
ia = (AdcaResultRegs.ADCRESULT0) * 1.3;
here ia is float type variable and declared globally.
When I am measuring the time taken by code to execute with the help of
GpioDataRegs.GPASET.bit.GPIO31 =1 ;//to profile code timing
ia = (AdcaResultRegs.ADCRESULT0) * 1.3;
GpioDataRegs.GPACLEAR.bit.GPIO31 =1 ;//to profile code timing
It takes 1 micro second time.
I have even enabled the TMU support for device (see the compiler flags below)
-v28 -ml -mt --cla_support=cla1 --float_support=fpu32 --tmu_support=tmu0 --fp_mode=relaxed --include_path="C:/ti/ccsv6/tools/compiler/ti-cgt-c2000_16.9.0.LTS/include" --include_path="D:/projects/background study software/freq variable/hw_files" --advice:performance=all -g --diag_warning=225 --diag_wrap=off --display_error_number
Here is the dis assembly of the above code
0821be: E801FD30 MOVIZ R0, #0x3fa6
0821c0: 761F002C MOVW DP, #0x2c
0821c2: E2C40100 UI16TOF32 R1H, @0x0
0821c4: E80B3330 MOVXI R0H, #0x6666
0821c6: E7000040 MPYF32 R0H, R0H, R1H
0821c8: 761F0242 MOVW DP, #0x242
0821ca: E2030020 MOV32 @0x20, R0H
I don’t understand why this much time is being taken.
Multiplication is supposed to be a single cycle instruction.
Can you please help me with this issue?