Skip to content

Commit

Permalink
修改线程池
Browse files Browse the repository at this point in the history
  • Loading branch information
黄宇扬 committed May 13, 2024
1 parent c4521a9 commit f985196
Show file tree
Hide file tree
Showing 4 changed files with 967 additions and 738 deletions.
2 changes: 0 additions & 2 deletions include/devices/cpu/cpudevice.h
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,6 @@
#define FASTLLM_CPUDEVICE_H

#include "device.h"
#include "cputhreadpool.h"
#include "alivethreadpool.h"

namespace fastllm {
Expand All @@ -21,7 +20,6 @@ namespace fastllm {
bool CopyDataFromCPU(void *dst, void *src, size_t size); // 不重要, cpu device不会进行这个操作

int threads = 4;
ThreadPool *threadPool = nullptr;
};

class CpuToFloat16 : BaseOperator {
Expand Down
2 changes: 0 additions & 2 deletions include/fastllm.h
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,6 @@
#include <memory>
#include <locale>
#include <codecvt>
#include "devices/cpu/cputhreadpool.h"
#include "devices/cpu/alivethreadpool.h"

#ifdef USE_SENTENCEPIECE
Expand All @@ -36,7 +35,6 @@ namespace fastllm {
bool GetLowMemMode();
int GetThreads();
bool GetKVCacheInCPU();
ThreadPool *GetPool();
AliveThreadPool *GetAlivePool();

struct GenerationConfig {
Expand Down
Loading

0 comments on commit f985196

Please sign in to comment.