<commit_before>// RUN: %clangxx_tsan -O0 %s -o %t
// RUN: env %env_tsan_opts=stack_trace_format=DEFAULT %deflake %run %t 2>&1 | FileCheck %s

#include "test.h"
#include <pthread.h>
#include <stdint.h>
#include <stdio.h>
#include <stdlib.h>

#if !__APPLE__
#include <sys/types.h>
#endif

extern "C" int __tsan_get_alloc_stack(void *addr, void **trace, size_t size,
                                      int *thread_id, void *os_id);

char *mem;
void alloc_func() { mem = (char *)malloc(10); }

void *AllocThread(void *context) {
  uint64_t tid;
#if __APPLE__
  pthread_threadid_np(NULL, &tid);
#else<commit_msg>More fixup for r290119: Make the ifdef work.<commit_after>// RUN: %clangxx_tsan -O0 %s -o %t
// RUN: env %env_tsan_opts=stack_trace_format=DEFAULT %deflake %run %t 2>&1 | FileCheck %s

#include "test.h"
#include <pthread.h>
#include <stdint.h>
#include <stdio.h>
#include <stdlib.h>

#ifndef __APPLE__
#include <sys/types.h>
#endif

extern "C" int __tsan_get_alloc_stack(void *addr, void **trace, size_t size,
                                      int *thread_id, void *os_id);

char *mem;
void alloc_func() { mem = (char *)malloc(10); }

void *AllocThread(void *context) {
  uint64_t tid;
#ifdef __APPLE__
  pthread_threadid_np(NULL, &tid);
#else
{'fraction_non_alphanumeric': 0.147175815433572, 'fraction_numerical': 0.015910898965791568, 'mean_word_length': 3.8199233716475094, 'pattern_counts': {'":': 0, '<': 13, '<?xml version=': 0, '>': 15, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 4, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '1054381', 'n_tokens_mistral': 516, 'n_tokens_neox': 494, 'n_words': 128}