ok I remove the patch for ioctl and manually change the fatal to warn.
Can you verify the followings:

1) in arch/x86/linux/syscalls.cc
    /*  16 */ SyscallDesc("ioctl", ioctlFunc<X86Linux64>),
    /*  54 */ SyscallDesc("ioctl", ioctlFunc<X86Linux32>),

2) in sim/syscall_emul.hh
template <class OS>
SyscallReturn
ioctlFunc(SyscallDesc *desc, int callnum, LiveProcess *process,
          ThreadContext *tc)
{
    int index = 0;
    int fd = process->getSyscallArg(tc, index);
    unsigned req = process->getSyscallArg(tc, index);

    DPRINTF(SyscallVerbose, "ioctl(%d, 0x%x, ...)\n", fd, req);

    if (fd < 0 || process->sim_fd(fd) < 0) {
        // doesn't map to any simulator fd: not a valid target fd
        return -EBADF;
    }

    switch (req) {
      case OS::TIOCISATTY_:
      case OS::TIOCGETP_:
      case OS::TIOCSETP_:
      case OS::TIOCSETN_:
      case OS::TIOCSETC_:
      case OS::TIOCGETC_:
      case OS::TIOCGETS_:
      case OS::TIOCGETA_:
      case OS::TCSETAW_:
        return -ENOTTY;

      default:
        warn("Unsupported ioctl call: ioctl(%d, 0x%x, ...) @ \n",
              fd, req, tc->pcState());
    }
}


However I get this error while building:

In file included from build/X86/arch/x86/linux/syscalls.cc:44:
build/X86/sim/syscall_emul.hh: In function 'SyscallReturn
ioctlFunc(SyscallDesc*, int, LiveProcess*, ThreadContext*) [with OS =
X86Linux64]':
build/X86/arch/x86/linux/syscalls.cc:232:   instantiated from here
build/X86/sim/syscall_emul.hh:507: error: 'TIOCISATTY_' is not a
member of 'X86Linux64'
build/X86/sim/syscall_emul.hh:508: error: 'TIOCGETP_' is not a member
of 'X86Linux64'
build/X86/sim/syscall_emul.hh:509: error: 'TIOCSETP_' is not a member
of 'X86Linux64'
build/X86/sim/syscall_emul.hh:510: error: 'TIOCSETN_' is not a member
of 'X86Linux64'
build/X86/sim/syscall_emul.hh:511: error: 'TIOCSETC_' is not a member
of 'X86Linux64'
build/X86/sim/syscall_emul.hh:512: error: 'TIOCGETC_' is not a member
of 'X86Linux64'
build/X86/sim/syscall_emul.hh:513: error: 'TIOCGETS_' is not a member
of 'X86Linux64'
build/X86/sim/syscall_emul.hh:514: error: 'TIOCGETA_' is not a member
of 'X86Linux64'
build/X86/sim/syscall_emul.hh:515: error: 'TCSETAW_' is not a member
of 'X86Linux64'
build/X86/sim/syscall_emul.hh: In function 'SyscallReturn
ioctlFunc(SyscallDesc*, int, LiveProcess*, ThreadContext*) [with OS =
X86Linux32]':
build/X86/arch/x86/linux/syscalls.cc:549:   instantiated from here
build/X86/sim/syscall_emul.hh:507: error: 'TIOCISATTY_' is not a
member of 'X86Linux32'
build/X86/sim/syscall_emul.hh:508: error: 'TIOCGETP_' is not a member
of 'X86Linux32'
build/X86/sim/syscall_emul.hh:509: error: 'TIOCSETP_' is not a member
of 'X86Linux32'
build/X86/sim/syscall_emul.hh:510: error: 'TIOCSETN_' is not a member
of 'X86Linux32'
build/X86/sim/syscall_emul.hh:511: error: 'TIOCSETC_' is not a member
of 'X86Linux32'
build/X86/sim/syscall_emul.hh:512: error: 'TIOCGETC_' is not a member
of 'X86Linux32'
build/X86/sim/syscall_emul.hh:513: error: 'TIOCGETS_' is not a member
of 'X86Linux32'
build/X86/sim/syscall_emul.hh:514: error: 'TIOCGETA_' is not a member
of 'X86Linux32'
build/X86/sim/syscall_emul.hh:515: error: 'TCSETAW_' is not a member
of 'X86Linux32'
scons: *** [build/X86/arch/x86/linux/syscalls.do] Error 1


What is yours?

On 4/26/12, Ankita (Garg) Goel <[email protected]> wrote:
> I think that had not worked for me. Instead, I have changed the 'fatal' to
> 'warn' for syscalls that are unimplemented... I know thats maybe not right,
> but found no other way... with this I have actually run the benchmarks for
> large number of instructions with -F.
>
> On Thu, Apr 26, 2012 at 12:19 PM, Mahmood Naderan
> <[email protected]>wrote:
>
>> have you applied this patch for ioctl?
>> http://www.csl.cornell.edu/~vince/projects/m5/m5_03_x86_ioctl.patch
>>
>> On 4/26/12, Ankita (Garg) Goel <[email protected]> wrote:
>> > Ah yes I am using x86, but not seen that issue or maybe not paid
>> attention
>> > to that.. not sure.
>> >
>> > On Thu, Apr 26, 2012 at 11:56 AM, Mahmood Naderan
>> > <[email protected]>wrote:
>> >
>> >> Are using x86?
>> >> I modified as yours, however in the middle of simulation, both of them
>> >> eat all the memory (they quickly reach 30GB of memory).
>> >> I don't know are they correctly reading the input or not.
>> >>
>> >> On 4/26/12, Ankita (Garg) Goel <[email protected]> wrote:
>> >> > Hi Mahmood,
>> >> >
>> >> > The following has worked for me for gromacs and leslie3D:
>> >> >
>> >> > #435.gromacs
>> >> > gromacs = LiveProcess()
>> >> > gromacs.executable =  binary_dir+'435.gromacs/exe/gromacs_base.gem5'
>> >> > data=data_dir+'435.gromacs/data/ref/input/gromacs.tpr'
>> >> > gromacs.cmd = [gromacs.executable] +
>> >> ['-silent','-deffnm',data,'-nice','0']
>> >> >
>> >> > #437.leslie3d
>> >> > leslie3d=LiveProcess()
>> >> > leslie3d.executable =
>>  binary_dir+'437.leslie3d/exe/leslie3d_base.gem5'
>> >> > stdin=data_dir+'437.leslie3d/data/test/input/leslie3d.in'
>> >> > leslie3d.cmd = [leslie3d.executable]
>> >> > leslie3d.input=stdin
>> >> > leslie3d.output='leslie3d.stdout'
>> >> >
>> >> > I think these are the same as mentioned on the wiki, not sure
>> >> > though.
>> >> Hope
>> >> > that helps!
>> >> >
>> >> > Regards,
>> >> > Ankita
>> >> >
>> >> > On Thu, Apr 26, 2012 at 9:18 AM, Mahmood Naderan
>> >> > <[email protected]>wrote:
>> >> >
>> >> >> Hi,
>> >> >> It seems that X86 SE mode has problems running some of spec
>> benchmarks
>> >> >> which use '<' for input reading. Examples are gamess, leslie3d,
>> >> >> tonto
>> >> >> and gromacs.
>> >> >>
>> >> >> Has anyone successfully run them? Please let me know.
>> >> >> --
>> >> >> // Naderan *Mahmood;
>> >> >> _______________________________________________
>> >> >> gem5-users mailing list
>> >> >> [email protected]
>> >> >> http://m5sim.org/cgi-bin/mailman/listinfo/gem5-users
>> >> >>
>> >> >
>> >> >
>> >> >
>> >> > --
>> >> > Regards,
>> >> > Ankita
>> >> > Graduate Student
>> >> > Department of Computer Science
>> >> > University of Texas at Austin
>> >> >
>> >>
>> >>
>> >> --
>> >> --
>> >> // Naderan *Mahmood;
>> >> _______________________________________________
>> >> gem5-users mailing list
>> >> [email protected]
>> >> http://m5sim.org/cgi-bin/mailman/listinfo/gem5-users
>> >>
>> >
>> >
>> >
>> > --
>> > Regards,
>> > Ankita
>> > Graduate Student
>> > Department of Computer Science
>> > University of Texas at Austin
>> >
>>
>>
>> --
>> --
>> // Naderan *Mahmood;
>> _______________________________________________
>> gem5-users mailing list
>> [email protected]
>> http://m5sim.org/cgi-bin/mailman/listinfo/gem5-users
>>
>
>
>
> --
> Regards,
> Ankita
> Graduate Student
> Department of Computer Science
> University of Texas at Austin
>


-- 
--
// Naderan *Mahmood;
_______________________________________________
gem5-users mailing list
[email protected]
http://m5sim.org/cgi-bin/mailman/listinfo/gem5-users

Reply via email to