Skip to content

Commit

Permalink
wip
Browse files Browse the repository at this point in the history
  • Loading branch information
chhwang committed Apr 24, 2024
1 parent 20840bb commit 432d777
Show file tree
Hide file tree
Showing 187 changed files with 5,810 additions and 2,675 deletions.
2 changes: 1 addition & 1 deletion .vscode/launch.json
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
"name": "ops_cast_test",
"type": "cppdbg",
"request": "launch",
"program": "${workspaceFolder}/build/ark/ops_cast_test",
"program": "${workspaceFolder}/build/ark/executor_test",
"args": [],
"stopAtEntry": false,
"cwd": "${fileDirname}",
Expand Down
101 changes: 101 additions & 0 deletions .vscode/settings.json
Original file line number Diff line number Diff line change
Expand Up @@ -10,4 +10,105 @@
"cmake.ctestArgs": [
"--verbose"
],
"files.associations": {
"ostream": "cpp",
"stdexcept": "cpp",
"string": "cpp",
"iosfwd": "cpp",
"memory": "cpp",
"stack": "cpp",
"any": "cpp",
"array": "cpp",
"atomic": "cpp",
"bit": "cpp",
"*.tcc": "cpp",
"bitset": "cpp",
"cctype": "cpp",
"cfenv": "cpp",
"chrono": "cpp",
"cinttypes": "cpp",
"clocale": "cpp",
"cmath": "cpp",
"codecvt": "cpp",
"compare": "cpp",
"complex": "cpp",
"concepts": "cpp",
"condition_variable": "cpp",
"csignal": "cpp",
"cstdarg": "cpp",
"cstddef": "cpp",
"cstdint": "cpp",
"cstdio": "cpp",
"cstdlib": "cpp",
"cstring": "cpp",
"ctime": "cpp",
"cwchar": "cpp",
"cwctype": "cpp",
"deque": "cpp",
"forward_list": "cpp",
"list": "cpp",
"map": "cpp",
"set": "cpp",
"unordered_map": "cpp",
"unordered_set": "cpp",
"vector": "cpp",
"exception": "cpp",
"algorithm": "cpp",
"functional": "cpp",
"iterator": "cpp",
"memory_resource": "cpp",
"numeric": "cpp",
"optional": "cpp",
"random": "cpp",
"ratio": "cpp",
"regex": "cpp",
"string_view": "cpp",
"system_error": "cpp",
"tuple": "cpp",
"type_traits": "cpp",
"utility": "cpp",
"fstream": "cpp",
"future": "cpp",
"initializer_list": "cpp",
"iomanip": "cpp",
"iostream": "cpp",
"istream": "cpp",
"limits": "cpp",
"mutex": "cpp",
"new": "cpp",
"numbers": "cpp",
"ranges": "cpp",
"semaphore": "cpp",
"span": "cpp",
"sstream": "cpp",
"stop_token": "cpp",
"streambuf": "cpp",
"thread": "cpp",
"typeinfo": "cpp",
"valarray": "cpp",
"variant": "cpp",
"__nullptr": "cpp",
"__hash_table": "cpp",
"__split_buffer": "cpp",
"__tree": "cpp",
"queue": "cpp",
"__locale": "cpp",
"*.ipp": "cpp",
"strstream": "cpp",
"typeindex": "cpp",
"locale": "cpp",
"__node_handle": "cpp",
"__threading_support": "cpp",
"__functional_03": "cpp",
"filesystem": "cpp",
"__bit_reference": "cpp",
"__config": "cpp",
"__debug": "cpp",
"version": "cpp",
"__functional_base": "cpp",
"__memory": "cpp",
"*.ci": "c",
"ark_kernels.h": "c"
},
"cmake.configureOnOpen": true,
}
6 changes: 3 additions & 3 deletions ark/CMakeLists.txt
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
# Copyright (c) Microsoft Corporation.
# Licensed under the MIT license.

file(GLOB_RECURSE SOURCES CONFIGURE_DEPENDS *.cc)
file(GLOB_RECURSE UT_SOURCES CONFIGURE_DEPENDS *_test.cc *_test.cu)
file(GLOB_RECURSE UT_COMMON_SOURCES CONFIGURE_DEPENDS ${CMAKE_CURRENT_SOURCE_DIR}/unittest/*.cc)
file(GLOB_RECURSE SOURCES CONFIGURE_DEPENDS *.cpp)
file(GLOB_RECURSE UT_SOURCES CONFIGURE_DEPENDS *_test.cpp)
file(GLOB_RECURSE UT_COMMON_SOURCES CONFIGURE_DEPENDS ${CMAKE_CURRENT_SOURCE_DIR}/unittest/*.cpp)
list(REMOVE_ITEM SOURCES ${UT_SOURCES} ${UT_COMMON_SOURCES})

if(USE_ROCM)
Expand Down
File renamed without changes.
2 changes: 2 additions & 0 deletions ark/bfloat16.h
Original file line number Diff line number Diff line change
Expand Up @@ -144,6 +144,8 @@ struct alignas(2) bfloat16_t {
int mantissa() const { return int(raw() & 0x7f); }
};

using bf16 = bfloat16_t;

/// Assignment from half_t
template <>
bfloat16_t& bfloat16_t::operator=(bfloat16_t const& x);
Expand Down
2 changes: 0 additions & 2 deletions ark/bfloat16_test.cc → ark/bfloat16_test.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,6 @@

#include "bfloat16.h"

#include "include/ark.h"
#include "unittest/unittest_utils.h"

ark::unittest::State test_bfloat16() {
Expand Down Expand Up @@ -246,7 +245,6 @@ ark::unittest::State test_bfloat16_error() {
}

int main() {
ark::init();
UNITTEST(test_bfloat16);
UNITTEST(test_bfloat16_error);
return 0;
Expand Down
Loading

0 comments on commit 432d777

Please sign in to comment.