Login
Username:

Password:

Remember me



Lost Password?

Register now!

Sections

Who's Online
185 user(s) are online (163 user(s) are browsing Forums)

Members: 1
Guests: 184

AmigaSociety, more...

Support us!

Headlines

 
  Register To Post  

« 1 ... 19 20 21 (22) 23 24 25 ... 72 »
Re: Odyssey 1.23 progress
Just popping in
Just popping in


See User information
I don't understand any words that you are talking about but guys, you are doing hard work and I appreciate it!

Go to top
Re: Odyssey 1.23 progress
Not too shy to talk
Not too shy to talk


See User information
I agree with Breed -- no understanding of what you all are talking about, but nonetheless I find it fascinating. Also, appreciate the efforts very much. Keep it up!

Go to top
Re: Odyssey 1.23 progress
Quite a regular
Quite a regular


See User information
@kas1e

You are doing a big, great job keep time no one here are asking you have to hurry :) ... if some one do can make the port him self, and i think you are the only one who take this strong big huge job

Go to top
Re: Odyssey 1.23 progress
Home away from home
Home away from home


See User information
@joerg,andy

Do simple test:

// aos4: ppc-amigaos-gcc tc_userdata_test.c -o tc_userdata_test_aos4
// aos3: m68k-amigaos-gcc -noixemul tc_userdata_test.c -o tc_userdata_test_aos4
// mos:  ppc-morphos-gcc -noixemul tc_userdata_test.c -o tc_userdata_test_mos

#include <proto/exec.h>
#include <stdlib.h>

main()
{
#ifdef __amigaos4__
struct Task *IExec->FindTask(NULL);
t->tc_UserData IExec -> AllocSysObjectTags(ASOT_LISTASOLIST_MinTRUEASO_NoTrackFALSETAG_END);
#else
struct Task *FindTask(NULL);
t->tc_UserData = (struct MinList *) malloc(sizeof(struct MinList)); 
#endif

exit(0);
}


After running it in os3/winuae/kcon shell and it exit from back to shell: tc_UserData are null.

After running it in os4 shell and it exit from back to shell: tc_UserData are value (not null).

After running it in morphos shell and it exit from back to shell: tc_UserData are null.

What mean that tc_UserData auto-cleans in their shell when exit from program running in shell happens, as well as it was like this on os3's kcon too (and i assume on default one too?). Now question is: as it shell, and it the same for os3 as for mos too, then should our os4 shell be fixed to do the same? I mean is there any specification or something which told what for example old os3.x shell do with it, should it worry about at all, or its all up to developer who use tc_UserData. As its clear now, that only os4 shell do not clean tc_UserData on exit, while os3 and mos ones are.

Anyway, its clear now that because of that, Odyssey's code make assumption that on every run tc_UserData are NULL, and we need save and restore tc_UserData on run/exit for os4 (Done), but maybe our shell need fixing too.


Edited by kas1e on 2014/3/3 6:07:25
Edited by kas1e on 2014/3/3 6:08:46
Go to top
Re: Odyssey 1.23 progress
Home away from home
Home away from home


See User information
@joerg
I also do better look on that MachineStackMarker.cpp, and all that morphos code in no use there, but not because of MORPHOS (as we should be in), but because its all in the ENABLE(JSC_MULTIPLE_THREADS), which is not enabled for my build, and i do not know if it enabled for mos build, but as code is here, seems should be..

My current flags for build are:

Quote:

CXX_DEFINES = -DWTF_CHANGES -DWTF_USE_ICU_UNICODE=1 -DWTF_USE_CURL=1 -DHAVE_ACCESSIBILITY -DNDEBUG -DENABLE_YARR=1 -DENABLE_JSC_MULTIPLE_THREADS=0 -DENABLE_WTF_MULTIPLE_THREADS=1 -DXP_MORPHOS -DENABLE_PLUGIN_PACKAGE_SIMPLE_HASH=1 -DENABLE_NETSCAPE_PLUGIN_API=1 -DENABLE_SVG=1 -DENABLE_SVG_ANIMATION=1 -DENABLE_SVG_AS_IMAGE=1 -DENABLE_FILTERS=1 -DENABLE_SVG_FONTS=1 -DENABLE_SVG_FOREIGN_OBJECT=1 -DENABLE_SVG_USE=1 -DENABLE_FULLSCREEN_API=1 -DENABLE_CHANNEL_MESSAGING=1 -DENABLE_BLOB=1 -DENABLE_FILE_SYSTEM=1 -DENABLE_DATALIST=1 -DENABLE_CSS_BOX_DECORATION_BREAK=1 -DENABLE_CSS_IMAGE_SET=1 -DENABLE_DETAILS=1 -DENABLE_INPUT_TYPE_COLOR=1 -DENABLE_METER_TAG=1 -DENABLE_MICRODATA=1 -DENABLE_PROGRESS_TAG=1 -DENABLE_REGISTER_PROTOCOL_HANDLER=1 -DENABLE_VIDEO=1 -DENABLE_VIDEO_TRACK=1 -DENABLE_MEDIA_STATISTICS=1 -DENABLE_WEB_TIMING=1 -DUSE_FREETYPE=1 -DWTF_PLATFORM_CAIRO=1 -DBUILDING_CAIRO__=1 -DWTF_PLATFORM_BAL=1 -DWTF_USE_FREETYPE=1 -DBUILDING_JavaScriptCore -DSTATICALLY_LINKED_WITH_WTF


I can try to enable pthreads and get rid of mos code in those JSC_MULTITHREADED parts. If all that stuff will make in end faster usage for us. But imho easy and better way its just ENABLE_JSC_MULTIPLE_THREADS=1 and adapt those parts in morphos blocks, as whole code for sure do not want to be mixed.

Btw, your old owb done with -DWTF_USE_PTHREADS=1 and -DENABLE_JSC_MULTIPLE_THREADS=1 or without ?


Edited by kas1e on 2014/3/3 8:55:08
Edited by kas1e on 2014/3/3 8:57:59
Edited by kas1e on 2014/3/3 9:02:42
Edited by kas1e on 2014/3/3 9:09:57
Go to top
Re: Odyssey 1.23 progress
Home away from home
Home away from home


See User information
@kas1e

Quote:

Anyway, its clear now that because of that, Odyssey's code make assumption that on every run tc_UserData are NULL, and we need save and restore tc_UserData on run/exit for os4 (Done), but maybe our shell need fixing too.


Interesting, although it may not be the shell, it could be the c library startup code.


PS (KCON is *not* a shell its a console, the shell is part of DOS and is what actually runs commands etc, the console is where it displays it's output etc)


Go to top
Re: Odyssey 1.23 progress
Just can't stay away
Just can't stay away


See User information
@kas1e

Quote:
Btw, your old owb done with -DWTF_USE_PTHREADS=1 and -DENABLE_JSC_MULTIPLE_THREADS=1 or without ?
Which of the old OWB versions, 1.21 or 2.20?
The current version of OWB is build with WTF_USE_PTHREADS=1, HAVE_PTHREAD_RWLOCK=0, ENABLE_JSC_MULTIPLE_THREADS=0, ...

Go to top
Re: Odyssey 1.23 progress
Just can't stay away
Just can't stay away


See User information
Anyone else reading this thread like it is some sort of Voodoo spell book where only every third word is recognisable???

Keep up the good work!

Go to top
Re: Odyssey 1.23 progress
Home away from home
Home away from home


See User information
@Joerg

Maybe you can help with that MachineStackMarker stuff, i.e those 3 parts of code need os4 analog to make js threading works:

#elif OS(MORPHOS)
typedef double                  float64_t;
struct __QVector
{
        
u_int32_t       A;
        
u_int32_t       B;
        
u_int32_t       C;
        
u_int32_t       D;
__attribute__((aligned(16)));

typedef struct __QVector                vector128_t;

struct PPCRegFrame
{
        
u_int32_t               StackGap[4];            /* StackFrame Gap..so a function working
                                                         * with the PPCRegFrame as the GPR1 doesn`t                                                                                            * overwrite any contents with a LR store at 4(1)
                                                         */

        
u_int32_t               Version;                /* Version of the structure */
        
u_int32_t               Type;                   /* Type of the regframe */
        
u_int32_t               Flags;                  /* The filled up registers */
        
u_int32_t               State;                  /* State of the Thread(only used for Get) */

        
u_int32_t               SRR0;
        
u_int32_t               SRR1;
        
u_int32_t               LR;
        
u_int32_t               CTR;

        
u_int32_t               CR;
        
u_int32_t               XER;

        
u_int32_t               GPR[32];

        
float64_t               FPR[32];
        
float64_t               FPSCR;

        
u_int32_t               VSAVE;
        
u_int32_t               AlignPad0;
        
u_int32_t               AlignPad1;
        
u_int32_t               AlignPad2;
        
vector128_t             VSCR;
        
vector128_t             VMX[32];
        
/* no size
         */
};

typedef struct PPCRegFrame PlatformThreadRegisters;


Quote:

#elif OS(MORPHOS)
PlatformThreadRegisters *registers = (PlatformThreadRegisters *) ((struct Task *)platformThread)->tc_ETask->PPCRegFrame;
regs = *registers;
return 0;


And

Quote:

#elif OS(MORPHOS)
return (void *) regs.GPR[1];
#else


Its all from that http://kas1e.mikendezign.com/temp/findtask/MachineStackMarker.cpp

I.e for first part we need to make aos4 typedef for PlatformThreadRegisters , for second part way to get thread registers and in end need a way to get the stack pointer for another thread.

Sure it can be all different , but whatever. Just even some prototype idea will be ok to start with, and then we can adapt it to working state.


Go to top
Re: Odyssey 1.23 progress
Home away from home
Home away from home


See User information
@Fab
JS threading enabled for morphos builds ?

Just when i build morphos version of 1.23, it was disabled by default and i have -DENABLE_JSC_MULTIPLE_THREADS=0 in morphos build as well. But as code is here, i curious if it works on morphos already and enabled ?

Go to top
Re: Odyssey 1.23 progress
Just can't stay away
Just can't stay away


See User information
@kas1e

Quote:
Maybe you can help with that MachineStackMarker stuff, i.e those 3 parts of code need os4 analog to make js threading works:
You don't need any changes if you enable WTF_USE_PTHREADS, except for removing the OS(MORPHOS) parts, and with pthreads.library 53.11 or newer you don't need to disable HAVE_PTHREAD_RWLOCK.

You could use AmigaOS specific code instead, but why?
The MorphOS code makes no sense, unless it's a workaround for bugs in MorphOS, and it seems to be incomplete. For AmigaOS, and any AmigaOS compatible OS, you don't need PlatformThreadRegisters and can disable getPlatformThreadRegisters() and otherThreadStackPointer(), and use something like
void MachineThreads::gatherFromOtherThread(ConservativeRootsconservativeRootsThreadthread)
{
    
D(kprintf("gatherFromOtherThread\n"));

    
voidstackPointer = (struct Task *)(thread->platformThread)->tc_SPReg//otherThreadStackPointer
    
voidstackBase thread->stackBase;
    
swapIfBackwards(stackPointerstackBase);
    
conservativeRoots.add(stackPointerstackBase);

    
D(kprintf("stackPointer %p stackBase %p\n"stackPointerstackBase));
}



suspendThread() should use IExec->SuspendTask(platformThread, 0) instead of Disable() which makes no sense at all (even for disabling multitasking completely instead of only stopping one task, which is wrong anyway, using IExec->Forbid() would have been enough) and resumeThread() IExec->RestartTask(platformThread, 0).

But since you always only post small, incomplete parts of the sources with which it's impossible to port it to AmigaOS you have to port it yourself if you don't want to use pthreads.

Go to top
Re: Odyssey 1.23 progress
Just can't stay away
Just can't stay away


See User information
@kas1e
Any memory allocated by malloc() is allocated by the C lbraries freed when the program exits. Memory allocated by AllocSysObjectTags() might not be freed unless FreeSysObject() is called before quitting the program. In fact, FreeSysObject() might not free the memory; it might just put it in a list for reuse for all we know. I think it's a non-issue.

Go to top
Re: Odyssey 1.23 progress
Just popping in
Just popping in


See User information
@kas1e

This multiple threads part is implemented and enabled in morphos, just so that webkit synchronization and compilation are made easier, but it's actually not used at all in practice (this code is used by external jsc clients, and possibly by webkit2, but not webkit itself). It's also totally unrelated to javascript workers, for instance.

Regarding the code itself, while Forbid() might be enough, I definitely wouldn't recommend Suspend/RestartTask.

@xenic

Of course using malloc() is a non issue, if the underlying clib is properly done. In MorphOS, it internally uses a mempool and all the allocated memory is given back at exit.

On the other hand, i really wouldn't use directly AllocVec*/AllocMem* in WebKit, and especially JSCore, because it tends to leak a lot (due to remaining live js references/objects in allocated blocks), and as a consequence, the leaks wouldn't be recovered at all after program exit.

At least, if you really don't want to use malloc(), at least keep track of your allocation, or better, use a mempool.

Go to top
Re: Odyssey 1.23 progress
Home away from home
Home away from home


See User information
@Fab
Ok, not big deal and can skip it then.

Join us to improve dopus5!
AmigaOS4 on youtube
Go to top
Re: Odyssey 1.23 progress
Just popping in
Just popping in


See User information
@kas1e

Sorry for my impatience, but there are nothing to report since two days. Maybe you have surely other things to do or could this mean we will see a Beta release soon?

Go to top
Re: Odyssey 1.23 progress
Home away from home
Home away from home


See User information
@younghippie
All done, just waiting for new mui release, because:

1). new version of odyssey want new mui class for autoform filling (which is done and will be released in new version of mui).
2). in new version of mui fixed all bugs related to tabs, so i will set minimum req to that mui on startup as well, so no reports from old mui will be about crashes in tabs.
3). few bugs related to odyssey was fixed too in mui

But in terms of whole port all done (without fullscreen youtube of course, just a window, when it will be done it can be then released as update or with next version of odyssey or something).

In other words waiting for new mui release (when , dunno, but i assume pretty soon)

Go to top
Re: Odyssey 1.23 progress
Quite a regular
Quite a regular


See User information
@kas1e


Go to top
Re: Odyssey 1.23 progress
Just popping in
Just popping in


See User information
Big Bravo Kas1e !

Sam460ex
Os4.1 Final Edition
2GB Fast Memory
envy 24 HT sound card
HD R9 TRIX 280X 3GO GDDR5
Go to top
Re: Odyssey 1.23 progress
Quite a regular
Quite a regular


See User information
Well done Roman

Amiga600/Vampire2/PrismaMegaMix​/32GB CF Card/2x Rys Mk2/A604n/IndivisionECS/Gotek
Go to top
Re: Odyssey 1.23 progress
Amigans Defender
Amigans Defender


See User information
Big THUMBS UP!

The Rear Window blog

AmigaOne X5000 @ 2GHz / 4GB RAM / Radeon RX 560 / ESI Juli@ / AmigaOS 4.1 Final Edition
SAM440ep-flex @ 667MHz / 1GB RAM / Radeon 9250 / AmigaOS 4.1 Final Edition
Go to top

  Register To Post
« 1 ... 19 20 21 (22) 23 24 25 ... 72 »

 




Currently Active Users Viewing This Thread: 3 ( 0 members and 3 Anonymous Users )




Powered by XOOPS 2.0 © 2001-2024 The XOOPS Project