This is the mail archive of the java-patches@gcc.gnu.org mailing list for the Java project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: RFA: [PATCH]: MIPS enhancements to libgcj...


On Tue, 21 Oct 2003, David Daney wrote:
> >Probably want a memory clobber here...
> >
> Perhaps, can anyone verify that?

At a minimum, you should have something like i386:

  __asm__ __volatile__(" " : : : "memory");
  *(addr) = new_val;

The "memory" clobber prevents GCC from moving loads and stores across the
asm.

> Or if "sync" is even needed?

Depending on the memory model, it may be essential on multiprocessor
systems.

> Or if "sync" is available on most/all CPUs?

No idea.  Surely a MIPS architecture manual would tell you (if there is
such a thing).

Jeff


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]