Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/marian-nmt/FBGEMM.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJianyu Huang <jianyuhuang@fb.com>2020-04-10 08:55:34 +0300
committerFacebook GitHub Bot <facebook-github-bot@users.noreply.github.com>2020-04-10 08:59:35 +0300
commit20b6cf14e2b547987234e39d922bc22ec541c3b4 (patch)
tree5459828c84d0d8dffdfe5a5b69f86557824abd4b /include/fbgemm/FbgemmFakeFP16.h
parentf1d333089f9442e48af73abe73148516a3bab110 (diff)
Move FakeFP16 back to internal to remove dependency on MKL (#36297)
Summary: Pull Request resolved: https://github.com/pytorch/pytorch/pull/36297 Pull Request resolved: https://github.com/pytorch/FBGEMM/pull/343 We moved FakeFP16 back to close source and kept `RoundToFloat16` function in "fbgemm/FbgemmConvert.h". This is because FakeFP16 introduced dependency on MKL in the FBGEMM core. Also it doesn't seem to be needed for open source, as it is not used anywhere. Reviewed By: jspark1105 Differential Revision: D20937962 fbshipit-source-id: 9487a9fd2282b6df2f754c22bea36f2255a5c791
Diffstat (limited to 'include/fbgemm/FbgemmFakeFP16.h')
-rw-r--r--include/fbgemm/FbgemmFakeFP16.h59
1 files changed, 0 insertions, 59 deletions
diff --git a/include/fbgemm/FbgemmFakeFP16.h b/include/fbgemm/FbgemmFakeFP16.h
deleted file mode 100644
index 3a9dc07..0000000
--- a/include/fbgemm/FbgemmFakeFP16.h
+++ /dev/null
@@ -1,59 +0,0 @@
-/*
- * Copyright (c) Facebook, Inc. and its affiliates.
- * All rights reserved.
- * This source code is licensed under the BSD-style license found in the
- * LICENSE file in the root directory of this source tree.
- */
-#pragma once
-
-#include "fbgemm/FbgemmConvert.h"
-#include "fbgemm/Types.h"
-#include "fbgemm/Utils.h"
-
-// Turning on this option will print out time breakdown of each stage (e.g.,
-// pre-processing fp32 -> fp16 conversion, the main GEMM kernel, post-processing
-// fp16 -> fp32 conversion). Please note that currently this option won't report
-// accurate timing if multiple threads are used. #define
-// FBGEMM_MEASURE_TIME_BREAKDOWN
-
-// #define FBGEMM_MEASURE_TIME_BREAKDOWN
-
-#ifdef FBGEMM_MEASURE_TIME_BREAKDOWN
-#include <chrono>
-#include <iostream>
-extern double malloc_time;
-extern double A_fp16_to_fp32_time;
-extern double B_fp16_to_fp32_time;
-extern double C_fp16_to_fp32_time;
-extern double computing_time;
-extern double C_fp32_to_fp16_time;
-extern double run_time;
-#endif
-
-namespace fbgemm {
-
-// typedef uint16_t float16;
-
-/**
- * @ Transform all entries in a matrix from fp32 to float16 and back to fp32
- *
- */
-FBGEMM_API void RoundToFloat16(
- const float* input,
- float* output,
- int len,
- bool clamp = false,
- bool clamp_denorms = false);
-
-FBGEMM_API void fbgemmFakeFP16(
- const matrix_op_t transa,
- const matrix_op_t transb,
- int m,
- int n,
- int k,
- const float16* A_float16,
- const float16* B_float16,
- float beta,
- float16* C_float16);
-
-}; // namespace fbgemm