#ifndef _PROFILER_XPROF_TYPE_H_
#define _PROFILER_XPROF_TYPE_H_

#if USE_XPROF_STATS

// TODO: auto-generate this list from a scan of the source code.

// This list MUST be kept in sync with the PROF_start()/PROF_stop() macros
// used throughout the rest of the sources.

typedef enum {
    XPROF_PROF_UNACCOUNTED,
    XPROF_PROF_OVERHEAD,
    XPROF_hash_lookup,
    XPROF_splay_splay,
    XPROF_xmalloc,
    XPROF_malloc,
    XPROF_free,
    XPROF_free_const,
    XPROF_xrealloc,
    XPROF_realloc,
    XPROF_xcalloc,
    XPROF_calloc,
    XPROF_xstrdup,
    XPROF_xstrndup,
    XPROF_xstrncpy,
    XPROF_xcountws,
    XPROF_socket,
    XPROF_read,
    XPROF_write,
    XPROF_send,
    XPROF_recv,
    XPROF_sendto,
    XPROF_recvfrom,
    XPROF_accept,
    XPROF_connect,
    XPROF_memPoolChunkNew,
    XPROF_memPoolAlloc,
    XPROF_memPoolFree,
    XPROF_memPoolClean,
    XPROF_aclMatchAclList,
    XPROF_aclCheckFast,
    XPROF_comm_open,
    XPROF_comm_connect_addr,
    XPROF_comm_accept,
    XPROF_comm_close,
    XPROF_comm_udp_sendto,
    XPROF_commHandleWrite,
    XPROF_comm_check_incoming,
    XPROF_comm_poll_prep_pfds,
    XPROF_comm_poll_normal,
    XPROF_comm_handle_ready_fd,
    XPROF_comm_read_handler,
    XPROF_comm_write_handler,
    XPROF_storeGet,
    XPROF_storeMaintainSwapSpace,
    XPROF_storeRelease,
    XPROF_diskHandleWrite,
    XPROF_diskHandleRead,
    XPROF_file_open,
    XPROF_file_read,
    XPROF_file_write,
    XPROF_file_close,
    XPROF_esiExpressionEval,
    XPROF_esiProcessing,
    XPROF_esiParsing,
    XPROF_storeClient_kickReads,
    XPROF_eventRun,
    XPROF_storeDirCallback,
    XPROF_comm_calliocallback,
    XPROF_CommReadCallbackData_callCallback,
    XPROF_CommAcceptCallbackData_callCallback,
    XPROF_CommWriteCallbackData_callCallback,
    XPROF_CommFillCallbackData_callCallback,
    XPROF_HttpStateData_readReply,
    XPROF_HttpStateData_processReplyBody,
    XPROF_StoreEntry_write,
    XPROF_storeGetMemSpace,
    XPROF_MemObject_write,
    XPROF_storeWriteComplete,
    XPROF_mem_hdr_write,
    XPROF_headersEnd,
    XPROF_parseHttpRequest,
    XPROF_HttpStateData_processReplyHeader,
    XPROF_MemBuf_consume,
    XPROF_MemBuf_append,
    XPROF_MemBuf_grow,
    XPROF_InvokeHandlers,
    XPROF_HttpMsg_httpMsgParseStep,
    XPROF_EventDispatcher_dispatch,
    XPROF_SignalEngine_checkEvents,
    XPROF_Temp1,
    XPROF_Temp2,
    XPROF_Temp3,
    XPROF_clientSocketRecipient,
    XPROF_httpStart,
    XPROF_HttpParserParseReqLine,
    XPROF_httpRequestFree,
    XPROF_HttpHeaderParse,
    XPROF_HttpHeaderClean,
    XPROF_StringInitBuf,
    XPROF_StringAllocAndFill,
    XPROF_StringClean,
    XPROF_StringReset,
    XPROF_StringAppend,
    XPROF_HttpHeader_findEntry,
    XPROF_HttpHeader_getCc,
    XPROF_HttpHeader_getRange,
    XPROF_checkTimeouts,
    XPROF_CommSelect,
    XPROF_LAST
} xprof_type;

#endif /* USE_XPROF_STATS */
#endif /* _PROFILING_H_ */
