use sid as thread id