Login
Username:

Password:

Remember me



Lost Password?

Register now!

Sections

Who's Online
96 user(s) are online (47 user(s) are browsing Forums)

Members: 2
Guests: 94

bigmac, flash, more...

Headlines

Forum Index


Board index » All Posts (sailor)




Re: A1222 support in the SDK and problems
Not too shy to talk
Not too shy to talk


@joergQuote:

- Build everything which doesn't use (much) float/double code with -msoft-float and use the soft-float C library.
- Put code which uses float/double calculations in separate sources compiled with -mabi=spe -mfloat-gprs=double instead.

And what if I need to use math library functions ( sin,cos..)? Do you know, what is faster? To call it newlib + standard powerpc way, i.e. it uses LTE emulator, or to use clib2 + integer emulation from here?
Of course, I cam measure it, I am asking just for case.

Quote:
- Make sure SPE functions called from soft-float code, and the other way round, are compatible, for example by only using pointers to float/double instead of direct float/double parameters. May not even be required if they are compatible anyway, as salass00 wrote.

at least printf, fprintf and sin() are not identical ( newlib.library 53.84 )- calling from SPE code returns nonsence. These I tested.

AmigaOS3: Amiga 1200
AmigaOS4: Micro A1-C, AmigaOne XE, Pegasos II, Sam440ep, Sam440ep-flex, AmigaOne X1000
MorphOS: Efika 5200b, Pegasos I, Pegasos II, Powerbook, Mac Mini, iMac, Powermac Quad
Go to top


Re: A1222 support in the SDK and problems
Not too shy to talk
Not too shy to talk


@joerg
@salass00

Thank you for explanation.

AmigaOS3: Amiga 1200
AmigaOS4: Micro A1-C, AmigaOne XE, Pegasos II, Sam440ep, Sam440ep-flex, AmigaOne X1000
MorphOS: Efika 5200b, Pegasos I, Pegasos II, Powerbook, Mac Mini, iMac, Powermac Quad
Go to top


Re: A1222 support in the SDK and problems
Not too shy to talk
Not too shy to talk


@flash

It is not so simple
From point of view of SPE embedded FPU it is HARD float, becouse it uses SPE-natural instructions and registers ( but these are not FPRs, but 64-bit GPRs ).
From point of view of powerpc code it is SOFT float, because it uses GPR registers and has no powerpc instructions.

From the point of view of gcc SPE code is SOFT float:
gcc -mcpu=8540 -mspe -mabi=spe -mfloat-gprs=double -c Stream2_mh.-o Stream2_mh.o
gcc 
-mcpu=powerpc -c spe_float_transition.-o spe_float_transition.o
gcc Stream2_mh
.o spe_float_transition.-o Stream2_mh
ld
Warningspe_float_transition.o uses hard floatStream2_mh uses soft float
Stream2_mh.c is benchmark compilled with SPE, spe_float_transition.c contains functions which should be called with powerpc float parameters, like printf.
gcc recognizes SPE code like soft-float.

If I remember good, comlilling with additional -mhard-float:
gcc -mcpu=8540 -mspe -mabi=spe -mfloat-gprs=double -mhard-float -c Stream2_mh.-o Stream2_mh.o
generates some error - but I can check it again.

And gcc 6.4.0 online docs says:
Quote:
-msoft-float
-mhard-float
Generate code that does not use (uses) the floating-point register set. Software floating-point emulation is provided if you use the -msoft-float option, and pass the option to GCC when linking.

And as if embedded spe FPU has no floating-point register set, it is recognized like soft


It is only my explanation, and of course, I can be wrong. I start to play with this only after A1222+ arrive, so there is a lot of things more to study.

AmigaOS3: Amiga 1200
AmigaOS4: Micro A1-C, AmigaOne XE, Pegasos II, Sam440ep, Sam440ep-flex, AmigaOne X1000
MorphOS: Efika 5200b, Pegasos I, Pegasos II, Powerbook, Mac Mini, iMac, Powermac Quad
Go to top


Re: A1222 support in the SDK and problems
Not too shy to talk
Not too shy to talk


@joergQuote:
joerg wrote:
You have to use gcc -msoft-float ...
But if you do not only your own code but all libraries, incl. the C library, you are using have to be compiled with -msoft-float as well. You can't mix FPU with soft-float code, at least not without using similar workarounds you are using for SPE now.

There is probably no soft-float version of newlib. There used to be soft-float versions of clib2, but in case it's no longer available rebuilding clib2 or clib4 with -msoft-float should be no big problem.
With a soft-float C library and building your own code with -msoft-float you don't need workarounds for functions like printf() either, but of course a SPE C library for the A1222 would be much better than a soft-float one which uses integer instructions and registers for float/double.


Thank you for detailed info.
And please, how to use soft-float C library?
Is it something like: "gcc -mcrt=clib2 -msoft-float .... -lm" ?
Or other way?

The spe code ( -mcpu=8540 -mabi=spe ) is allways soft-float, regardless of c library used.
And how is floating-point parameters passed when I used "-mcpu=powerpc -msoft-float" ? Via GPR registers? They are 32-bit in powerpc ABI. Or via stack? Or float via GPR and double via stack?
I read wiki.amigaos.net, but trere is not much about SPE.

AmigaOS3: Amiga 1200
AmigaOS4: Micro A1-C, AmigaOne XE, Pegasos II, Sam440ep, Sam440ep-flex, AmigaOne X1000
MorphOS: Efika 5200b, Pegasos I, Pegasos II, Powerbook, Mac Mini, iMac, Powermac Quad
Go to top


Re: A1222 support in the SDK and problems
Not too shy to talk
Not too shy to talk


@flashQuote:
flash wrote:@sailor
As workaround you need to pass float parameters by reference and not by value.
Another solution is to pass them using heap space and not stack.
To do this you can use an array of floats and pass it's base address to function.
Another solution is to pass a struct with floats vars as members.

Anyway also printf function is bugged for A1222 and need to be fixed for floats.

I am using the first workaround, and I wrote my printf float function alternative for for print for spe.

@HansQuote:
Hans wrote:@sailor
How could I make it more accessible to "blones, who did C-coding 25 years before?"

I am sorry Hans, it was joke. It only means, that for me was not enough to read your article, and I had to make some examples and experiments before I understood it completely. Nothing other needed. Thanks.

AmigaOS3: Amiga 1200
AmigaOS4: Micro A1-C, AmigaOne XE, Pegasos II, Sam440ep, Sam440ep-flex, AmigaOne X1000
MorphOS: Efika 5200b, Pegasos I, Pegasos II, Powerbook, Mac Mini, iMac, Powermac Quad
Go to top


Re: A1222 support in the SDK and problems
Not too shy to talk
Not too shy to talk


I have another question for SPE code:

If I need math library and using #include <math.h> and "-lm", it linked standart powerpc math code. I.e. it cannot be called directly from SPE code.
Now I am using the same workaround like in case of printf (above) - from SPE code call transition function by pointer, transition function is powerpc code and call math function normally.

But do exist in AmigaOS4 SDK some workaround?
I tried to use -lsoft-fp, but it not exists: "ld: cannot find -lsoft-fp"..

And please, what is "SDK:clib2/lib/soft-float/libm.a" for? Is it some preparation for soft-fp calls or something other? And how to use it?

Thanks for any tips and clues.

AmigaOS3: Amiga 1200
AmigaOS4: Micro A1-C, AmigaOne XE, Pegasos II, Sam440ep, Sam440ep-flex, AmigaOne X1000
MorphOS: Efika 5200b, Pegasos I, Pegasos II, Powerbook, Mac Mini, iMac, Powermac Quad
Go to top


Re: Attempting to upgrade Sam 440 with an R7 240 or HD 7770
Not too shy to talk
Not too shy to talk


@Hypex

you not need powered PCI-PCIe adapter - geennaam's scheme works for me.

Working and proved connection is:

1. Sam440ep-flex PCI 66 MHz
2. PCI-PCIe bridge ( second photo in paragraph 3.1 - this is with chip P17C9X. You need no additional power here, power is drawn from PCI slot.
3. PCIe x1 -> x16 powered riser (common name on ebay is Powered USB3.0 GPU Riser Extender or mining rig adapter ) - see photo three in the same paragraph. You have to connect this adapter to power.
4. PCIe x16 graphics card

This should works for all PCIe cards upto 75W. More powerful cards need additional power ( PCIe power plug 6-pin, 8-pin ). Above mentioned HD 7770 ( 80W) probably needs 1x 6-pin.

AmigaOS3: Amiga 1200
AmigaOS4: Micro A1-C, AmigaOne XE, Pegasos II, Sam440ep, Sam440ep-flex, AmigaOne X1000
MorphOS: Efika 5200b, Pegasos I, Pegasos II, Powerbook, Mac Mini, iMac, Powermac Quad
Go to top


Re: Pegasos2 with RadeonHD/RX via bridge
Not too shy to talk
Not too shy to talk


@kas1eQuote:

Can anybody help us with an idea of how to access properly the PCI configuration registers ? Or should be something done to make them accessible at all ? That what currently block Hans from progress in making working RadeonHD/RX cards via bridge on real pegasos2.


Unfortunatelly manual of Pegasos Smart Firmware is very short.
Only usable information I found is:
"SmartFirmware is an implementation of the OpenFirmware IEEE standard 1275-1994 plus errata changes"
And here is OpenFirmware Manual.
Maybe we can use some config-x writes...

Or maybe FCode helps?

@kas1eQuote:
kas1e wrote:@All
Does anyone know what the best PPC Linux which still support pegasos2 up-to-date , so we can see if bridge and some older HD cards supported by Linux are works on at all (so we can see what they do). Is Debian 8.2 is the last/best one to play with?


Yes, the last distro supporting Pegasos 2 is Debian 8. Or Ubuntu 16.04

AmigaOS3: Amiga 1200
AmigaOS4: Micro A1-C, AmigaOne XE, Pegasos II, Sam440ep, Sam440ep-flex, AmigaOne X1000
MorphOS: Efika 5200b, Pegasos I, Pegasos II, Powerbook, Mac Mini, iMac, Powermac Quad
Go to top


Re: Ragemem source code
Not too shy to talk
Not too shy to talk


@K-L @Kamelito
Thank you very much!

AmigaOS3: Amiga 1200
AmigaOS4: Micro A1-C, AmigaOne XE, Pegasos II, Sam440ep, Sam440ep-flex, AmigaOne X1000
MorphOS: Efika 5200b, Pegasos I, Pegasos II, Powerbook, Mac Mini, iMac, Powermac Quad
Go to top


Re: Trying to get a Radeon HD 7750 working in an AmigaOne XE
Not too shy to talk
Not too shy to talk


@mr2Quote:
mr2 wrote:Novabridge will not work because it need RadeonHD V5. And RadeonHD V5 is not available for the sam440.

Sailor said she wanted to try SAM460 RadeonHD v5 driver with SAM440. Both chips has the same core. I wonder what the result is....


Sam440ep + RadeonHD v5 (Sam460ex version) not works.
It is not exact - it boots to system, but performace is not good an va.libraty not works, so it is useless.

And regarding NovaBridge - I suppose that it works with RadeonHD v3.7. I will test it also and let you know.

AmigaOS3: Amiga 1200
AmigaOS4: Micro A1-C, AmigaOne XE, Pegasos II, Sam440ep, Sam440ep-flex, AmigaOne X1000
MorphOS: Efika 5200b, Pegasos I, Pegasos II, Powerbook, Mac Mini, iMac, Powermac Quad
Go to top


Ragemem source code
Not too shy to talk
Not too shy to talk


Please, do anybody contact for Crisot ( uploader of ragemem on os4depot )? He was not years on amiga forums.
Or do anybody have ragemem code. If is it opensource, of course.

I am interested in ragemem - I am now playing with A1222+ and ragemem do some floating-point math, so I want to compile it for SPE.

I allready compiled stream v5.10 both for spe and standart powerpc, but it measures only memory + fpu calculation speed.
And ragemem measures L1 and L2 also.

Or if you have tip for other L1 L2 tool or algorithm...

thanks!

AmigaOS3: Amiga 1200
AmigaOS4: Micro A1-C, AmigaOne XE, Pegasos II, Sam440ep, Sam440ep-flex, AmigaOne X1000
MorphOS: Efika 5200b, Pegasos I, Pegasos II, Powerbook, Mac Mini, iMac, Powermac Quad
Go to top


Re: SAM Flex Stuttering Issue workbench or software use / games
Not too shy to talk
Not too shy to talk


@GebrochenQuote:


Has anyone on here decided to push their sam 440 CPUs to go higher than 800mhz to be similar to the 460 (which actually uses a 440 cpu) performance wise?
On discord it seems no one has really been ballsy enough in case they ruin their expensive Amiga toy.


In real, Sam460ex not uses 440 CPU. It uses AMCC 460ex CPU. And Sam440ep uses AMCC 440ep CPU.
Both CPUs uses the same core ( PPC440 ), but the rest is different.
Take a look here for differences: 440ep 460ex.

For example Sam460ex/cr/LE has more than five times higher speed of write to video RAM.
And regarding of overclocking of Sam440ep: do it exactly like is recommended in Hyperclock: for frequencies above 800 MHz place fan on CPU cooler. In this case it is safe.

And if you want us to help you with graphics issues, it will be good to provide at least your version of RadeonHD.chip or Enhancer.
New RadeonHD is a must, if you use HD cards. If you use the one from AmigaOS installer CD, it is limited version only. And probably reason of stuttering.

AmigaOS3: Amiga 1200
AmigaOS4: Micro A1-C, AmigaOne XE, Pegasos II, Sam440ep, Sam440ep-flex, AmigaOne X1000
MorphOS: Efika 5200b, Pegasos I, Pegasos II, Powerbook, Mac Mini, iMac, Powermac Quad
Go to top


Re: Release 4.1 [460LE vs A1222]: The Price of Admission
Not too shy to talk
Not too shy to talk


Here is my 460LE vs A1222+ comparison:
Welterweight duel.
In Czech language as usual, the most interesting are cores on the end of articles.
Theoretical only, practical will follow.

AmigaOS3: Amiga 1200
AmigaOS4: Micro A1-C, AmigaOne XE, Pegasos II, Sam440ep, Sam440ep-flex, AmigaOne X1000
MorphOS: Efika 5200b, Pegasos I, Pegasos II, Powerbook, Mac Mini, iMac, Powermac Quad
Go to top


Re: Sam460LE 1.10 Ghz Pre-Order!
Not too shy to talk
Not too shy to talk


@Gebrochen

AmigaOS 4.1fe compatible hardware you will find on this page. In future probably there will be also HD audio driver, but it is not released for public yet.

About Sam460LE:
unlike Sam440ep-flex has no sound or SATA onboard.
it has three slots:
PCIe x16 - for graphics card. There is two slot free space, so you need no adapter.
PCI 66 MHz ( the white one) - most common is to put SATA card here: SiI3512 or 3114.
PCIe x1 - most common is to put sound card here.
If you have in plan use MorphOS too, only two cards are compatible with both systems: C-Media CMI8738, Envy24HT. Somebody also used USB sound - look here.I am not tested it.

I have in my Sam460LE: Southern Island HD7970 for testing Radeon HD ( but this one have high power ), in future there will be RX560. PCI SATA controller SiI3114 and PCIe soundcard CMI8738.

Edit: a little offtopic, but it is about compatibility AmigaOS/MorphOS/linux on powerpc big endian.


Edited by sailor on 2024/4/8 19:40:39
Edited by sailor on 2024/4/8 19:42:31
Edited by sailor on 2024/4/8 19:42:51
AmigaOS3: Amiga 1200
AmigaOS4: Micro A1-C, AmigaOne XE, Pegasos II, Sam440ep, Sam440ep-flex, AmigaOne X1000
MorphOS: Efika 5200b, Pegasos I, Pegasos II, Powerbook, Mac Mini, iMac, Powermac Quad
Go to top


Re: Updater tool: latest releases and updates
Not too shy to talk
Not too shy to talk


@PrimaxQuote:
Primax wrote:Does this only work with Sam 460ex (as written in your requirements)? Or also with the currently available model 460LE?


It should work with all Sam460 variants: ex/ex-lite/cr/LE.
All uses the same SOC CPU, so PCIe complex is allways the same.

For me it works in Sam460LE OOTB.

AmigaOS3: Amiga 1200
AmigaOS4: Micro A1-C, AmigaOne XE, Pegasos II, Sam440ep, Sam440ep-flex, AmigaOne X1000
MorphOS: Efika 5200b, Pegasos I, Pegasos II, Powerbook, Mac Mini, iMac, Powermac Quad
Go to top


Re: A1222 support in the SDK and problems
Not too shy to talk
Not too shy to talk


@joerg
thank you! It is exactly I needed.

AmigaOS3: Amiga 1200
AmigaOS4: Micro A1-C, AmigaOne XE, Pegasos II, Sam440ep, Sam440ep-flex, AmigaOne X1000
MorphOS: Efika 5200b, Pegasos I, Pegasos II, Powerbook, Mac Mini, iMac, Powermac Quad
Go to top


Re: A1222 support in the SDK and problems
Not too shy to talk
Not too shy to talk


@all
please, where I found powerpc calling conventions for gcc/AmigaOS?

Something like this asm AIX stuff?
Or some other info about stack values and so...

AmigaOS3: Amiga 1200
AmigaOS4: Micro A1-C, AmigaOne XE, Pegasos II, Sam440ep, Sam440ep-flex, AmigaOne X1000
MorphOS: Efika 5200b, Pegasos I, Pegasos II, Powerbook, Mac Mini, iMac, Powermac Quad
Go to top


Re: SAM Flex Stuttering Issue workbench or software use / games
Not too shy to talk
Not too shy to talk


@GebrochenQuote:
Gebrochen wrote:@sailor

Yeah so in the end that does not mean something less than 460 isnt supported, maybe they got lazy and just assumed people would be aware due to the close architecutre of the CPUs and hardware that it will work with 440, 460, 480 or even a 420... LOL, have no idea what other PPC AMC models are out there in the world that arent amiga platform related but yep....

If you could test if it works on your sam440, that would indeed be a grand gesture.


I am afraid there are some misunderstanding.

Warp3D Nova, opengles, RadeonHDv3.7 ( all this is in Enhancer ) + Nova Bridge ( for compatibility with MiniGL ) IS WORKING WITH SAM 460440-EP-FLEX. I am using it daily, and it is great. You can use radeon HD cards, the best are HD77xx-HD79xx, R7, R9 ( = southern Island ).

Mentioned RadeonHDv5 is only for X1000, X5000 and Sam460ex/cr/le.
In near future I will test also RadeonHDv5 on ( unsupported ) Sam440ep-flex. But version 3.7 is enough for all except HD videos.

Edit: corection 460->440 ^^^.


Edited by sailor on 2024/4/6 16:26:59
AmigaOS3: Amiga 1200
AmigaOS4: Micro A1-C, AmigaOne XE, Pegasos II, Sam440ep, Sam440ep-flex, AmigaOne X1000
MorphOS: Efika 5200b, Pegasos I, Pegasos II, Powerbook, Mac Mini, iMac, Powermac Quad
Go to top


Re: SAM Flex Stuttering Issue workbench or software use / games
Not too shy to talk
Not too shy to talk


@geennaam
information on wiki is not exact. Sam440ep-flex + PCI-PCie adapter is compatible with RadeonHD.chip upto v3.7 only.

I forgot where is official info about v5, but it is in all forums this way. And in all shops you can select only Sam460ex version, not 440.
A-Eon.

AmigaOS3: Amiga 1200
AmigaOS4: Micro A1-C, AmigaOne XE, Pegasos II, Sam440ep, Sam440ep-flex, AmigaOne X1000
MorphOS: Efika 5200b, Pegasos I, Pegasos II, Powerbook, Mac Mini, iMac, Powermac Quad
Go to top


Re: A1222 support in the SDK and problems
Not too shy to talk
Not too shy to talk


@geennaam

in this time it is no typo, only not ideal name
all above code is very dirty - I made it in the evening in a hurry. My dogs were hungry.

Probably in future I put all transition functions of project in one file. And use one naming convention something like:
origname_SPE() or origname_SPE_1 () .. if it uses different number of parameters than original. Like above printf(), it can print only one double.

Yes, SPE programming is the same as other SIMD programming. SPE has only shorter vectors and few functions.
If we have altivec code, things are relatively simple with one exception - Altivec permute unit instructions. There is no SPE alternative, so it should be carefully checked what the code exactly means...

And naming convention of spe.h is terrible, so I should have make some cheat seat first. I am using SPEPEM and also manual from the link. Thanks.


Edited by sailor on 2024/4/5 12:49:00
AmigaOS3: Amiga 1200
AmigaOS4: Micro A1-C, AmigaOne XE, Pegasos II, Sam440ep, Sam440ep-flex, AmigaOne X1000
MorphOS: Efika 5200b, Pegasos I, Pegasos II, Powerbook, Mac Mini, iMac, Powermac Quad
Go to top



TopTop
(1) 2 3 4 ... 20 »




Powered by XOOPS 2.0 © 2001-2023 The XOOPS Project