Skip to content

Conversation

@SARG-FB
Copy link
Contributor

@SARG-FB SARG-FB commented Oct 25, 2020

I didn't use 'rebase --onto master start ' just 'rebase master' on gas64_rev branch. Hope no issue.

  • fix sse41 test, before the asm test instruction was wrongly used.
  • fix wrong optimization for xmmN registers.
  • new optimizations canceling the above fix.
  • some changes in asm_info() lines, typos fixes

mov -xxx[rbp], rax --> mov -xxx[rbp], rax kept
mov rcx, -xxx[rbp] --> freebasic#2 mov rcx, -xxx[rbp] commented
mov rcx, rax new line

movq -xxx[rbp], xmm0 --> movq -xxx[rbp], xmm0 kept
movq xmm1, -xxx[rbp] --> freebasic#3 movq xmm1, -xxx[rbp] commented
movsd xmm1, xmm0 new line
… causing use of roundss/roundsd even with CPU non compatible
@jayrm
Copy link
Member

jayrm commented Oct 25, 2020

Thanks @SARG-FB . Looks like that should fix my mistake with the SSE41 tests in #261

Rebase is good. The PR is branched from current fbc/master, so that's perfect. It's nice to have the new changes on fbc/master as it makes picking commits for the fbc-1.07 branch very easy. Thank-you.

For the 4 sections beginning with ctx.roundfloat=true looks like there is enough duplicated code that it would be worth refactoring in to a private sub; something like private sub hEmitRoundFloat( ... ) or similar name. It would remove duplicate code and put the common task in one place -- if it needs to be changed in future, only have to change in one place rather than 4. Also makes the fbc executable a little smaller.

To update this PR, you can make the changes on your PC, and when ready push to your gas64_rev branch again. github will automatically update this PR and run travis-ci build tests again.

@jayrm jayrm merged commit ab9fbd3 into freebasic:master Oct 25, 2020
jayrm pushed a commit to jayrm/fbc that referenced this pull request Oct 26, 2020
(cherry picked from commit 67cdf68)

gas64 : fix incomplete test in optimization module
(cherry picked from commit f78ce79)

gas64 : new optimizations

mov -xxx[rbp], rax --> mov -xxx[rbp], rax kept
mov rcx, -xxx[rbp] --> freebasic#2 mov rcx, -xxx[rbp] commented
mov rcx, rax new line

movq -xxx[rbp], xmm0 --> movq -xxx[rbp], xmm0 kept
movq xmm1, -xxx[rbp] --> freebasic#3 movq xmm1, -xxx[rbp] commented
movsd xmm1, xmm0 new line
(cherry picked from commit 170d5db)

gas64 : fix wrong use of test sse41 when converting float to ulongint causing use of roundss/roundsd even with CPU non compatible
(cherry picked from commit 1b8d94a)

gas64 : removal of useless test in optimization (optim 3-1)
(cherry picked from commit 61cacf2)

gas64 : all 4 leading spaces replaced by tab (thanks to Notepad++)
	'By SARG' added (removed by error)
(cherry picked from commit 023cfeb)

gas64 : fix new optimizations....
(cherry picked from commit ff7867b)

Merge pull request freebasic#262 from SARG-FB/gas64_rev

gas64; sse41 checks and optimization fixes

- fix sse41 test, before the asm test instruction was wrongly used.
- fix wrong optimization for xmmN registers.
- new optimizations canceling the above fix.
- some changes in asm_info() lines, typos fixes
(cherry picked from commit ab9fbd3)
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.

2 participants