Skip to content

perf(moderate): replace pow() with bit shift in updateConversionParam… - #31

Open
lahirunirmalx wants to merge 1 commit into
CuriousScientist0:mainfrom
lahirunirmalx:dev-pow-optimization
Open

perf(moderate): replace pow() with bit shift in updateConversionParam…#31
lahirunirmalx wants to merge 1 commit into
CuriousScientist0:mainfrom
lahirunirmalx:dev-pow-optimization

Conversation

@lahirunirmalx

Copy link
Copy Markdown

…eter

  • Replace pow(2, _PGA) with (1 << _PGA) for integer power of 2
  • Avoids heavy floating-point pow() call from math library
  • Fixed incorrect comment: 8388608 = 2^23, not 2^23-1
  • Results in smaller code size and faster execution

…eter

- Replace pow(2, _PGA) with (1 << _PGA) for integer power of 2
- Avoids heavy floating-point pow() call from math library
- Fixed incorrect comment: 8388608 = 2^23, not 2^23-1
- Results in smaller code size and faster execution
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant