Dmitry Vyukov | 9190a03 | 2012-12-12 12:27:00 +0000 | [diff] [blame^] | 1 | //===-- tsan_fd.h -----------------------------------------------*- C++ -*-===// |
| 2 | // |
| 3 | // The LLVM Compiler Infrastructure |
| 4 | // |
| 5 | // This file is distributed under the University of Illinois Open Source |
| 6 | // License. See LICENSE.TXT for details. |
| 7 | // |
| 8 | //===----------------------------------------------------------------------===// |
| 9 | // |
| 10 | // This file is a part of ThreadSanitizer (TSan), a race detector. |
| 11 | // |
| 12 | //===----------------------------------------------------------------------===// |
| 13 | #ifndef TSAN_FD_H |
| 14 | #define TSAN_FD_H |
| 15 | |
| 16 | #include "tsan_rtl.h" |
| 17 | |
| 18 | namespace __tsan { |
| 19 | |
| 20 | void FdInit(); |
| 21 | void FdAcquire(ThreadState *thr, uptr pc, int fd); |
| 22 | void FdRelease(ThreadState *thr, uptr pc, int fd); |
| 23 | void FdClose(ThreadState *thr, uptr pc, int fd); |
| 24 | void FdFileCreate(ThreadState *thr, uptr pc, int fd); |
| 25 | void FdDup(ThreadState *thr, uptr pc, int oldfd, int newfd); |
| 26 | void FdPipeCreate(ThreadState *thr, uptr pc, int rfd, int wfd); |
| 27 | void FdEventCreate(ThreadState *thr, uptr pc, int fd); |
| 28 | void FdPollCreate(ThreadState *thr, uptr pc, int fd); |
| 29 | void FdSocketCreate(ThreadState *thr, uptr pc, int fd); |
| 30 | void FdSocketAccept(ThreadState *thr, uptr pc, int fd, int newfd); |
| 31 | void FdSocketConnect(ThreadState *thr, uptr pc, int fd); |
| 32 | |
| 33 | uptr File2addr(char *path); |
| 34 | uptr Dir2addr(char *path); |
| 35 | |
| 36 | } // namespace __tsan |
| 37 | |
| 38 | #endif // TSAN_INTERFACE_H |