External DLL calls with 5 arguments don't work on Windows x86-64 #21
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue
	
	
	No description provided.
		
		Delete branch "%!s()"
	 
	Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Example
Error:
exit status 0xc0000005 (Access Violation)
Thanks!
Fixed in
cli/q@4f423c5a95.I was able to draw a green line from
10, 10to100, 100but for some reason I still have some troubles with the original coordinates in your report.Edit:
I think the optimizer might be doing something weird here. It only works if I use starting coordinates with numbers that already appeared in the code before. That's definitely pointing towards an internal optimization bug.
Original coordinates works for me (Also tested some more coords and it works)
Could it be a wine issue?
Edit I tried some more coords
if any of the args is 0 it says: panic: shift destination cannot be R1
I tried line from 10, 10 to 100, 100 and it said: panic: no free registers
Could you please post the working code? Then I can compare to see what's going on.
I use dll from raylib-5.5_win64_msvc16.zip on github releases
External DLL calls with more than 3 arguments doesn't work [Windows x86-64]to External DLL calls with 5 arguments don't work on Windows x86-64Fixed in
cli/q@26099e691c.I reduced the pressure on registers significantly.
It seems to work with any coordinates now.
Fun fact, I get 8k FPS in Windows and 16k FPS in Linux/WINE 😄
The commit also improved the performance.
There are still a few optimizations left that we can do for DLL calls on Windows, so it can be even higher.
Feel free to close the issue if it works for you!
Getting more fps on linux is really funny lol I wish I could switch to linux one day (my manufacturer has a terrible linux support literally unusable)
I encountered some more issues but Im not sure if they are related to dll calls or structs
also I feel like Im spamming issues Im sure you have other stuff to do and I don't want to rush you
panic: runtime error: invalid memory address or nil pointer dereference
[signal 0xc0000005 code=0x0 addr=0x38 pc=0x7ff7a50ce864]
goroutine 34 [running]:
git.urbach.dev/cli/q/src/core.(*Function).evaluateStruct(0xc000102180, 0xc000194990)
C:/Furkan/Dev/q/src/core/evaluateStruct.go:35 +0x2c4
git.urbach.dev/cli/q/src/core.(*Function).evaluate(0xc0001c64b0?, 0xc00018e180?)
C:/Furkan/Dev/q/src/core/evaluate.go:26 +0x71
........
........
I took a look at it and it's related to struct fields missing commas, so that one would be a different topic.
I will add a proper error message to the compiler.
Don't worry! Your bug reports are very useful!
Error messages for struct evaluation are now available in
cli/q@4af3c3283a.I prefer to have one issue for each topic, so if you find 3 new problems then please feel free to open 3 different issues!
It's not spamming, it actually helps me focus on one topic at a time.
Thanks, I'm closing the issue now