This is the mail archive of the libc-alpha@sourceware.org mailing list for the glibc 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: [RFC PATCH] Test for syscall templates


On Fri, Feb 10, 2017 at 8:27 AM, Yury Norov <ynorov@caviumnetworks.com> wrote:
> On Fri, Feb 10, 2017 at 07:51:07AM -0500, Zack Weinberg wrote:
>> On Fri, Feb 10, 2017 at 5:10 AM, Yury Norov <ynorov@caviumnetworks.com> wrote:
>> >
>> > This is RFC because I'm not sure this is right way to check the macro
>>
>> The way to make this a better test, and ensure you're not just testing
>> one of several possible implementations of the
>> trap-to-kernel-then-set-errno sequence, is to apply the same test to
>> _as many syscalls as practical_.
>
> So I only tried to test error path of syscall template. If you think
> that the correct way to do it is to call each syscall that may fail
> in each possible scenario - then I think glibc don't need the test
> like that, and we'd run LTP to find bugs of that sort - like I did in
> this case.

You asked how to make the test better.  I told you how I think you
could make the test better.

I realize I'm asking for some extra work, but it should not take more
than a half hour and it really will be a better test this way.

(I _do_ think glibc should have a test like this.  It does not require
elaborate setup, and the more bugs we can catch _during development_,
rather than months after the fact when someone thinks to run LTP, the
better.)

zw


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