/* Intel 387 floating point stuff.
Copyright (C) 1988, 1989, 1991, 1992, 1993, 1994, 1998, 1999, 2000, 2001,
- 2002, 2003, 2004, 2005, 2007, 2008, 2009 Free Software Foundation, Inc.
+ 2002, 2003, 2004, 2005, 2007, 2008, 2009, 2010
+ Free Software Foundation, Inc.
This file is part of GDB.
void
i387_supply_fsave (struct regcache *regcache, int regnum, const void *fsave)
{
- struct gdbarch_tdep *tdep = gdbarch_tdep (get_regcache_arch (regcache));
+ struct gdbarch *gdbarch = get_regcache_arch (regcache);
+ struct gdbarch_tdep *tdep = gdbarch_tdep (gdbarch);
+ enum bfd_endian byte_order = gdbarch_byte_order (gdbarch);
const gdb_byte *regs = fsave;
int i;
{
gdb_byte buf[4];
- store_unsigned_integer (buf, 4, 0x1f80);
+ store_unsigned_integer (buf, 4, byte_order, 0x1f80);
regcache_raw_supply (regcache, I387_MXCSR_REGNUM (tdep), buf);
}
}