clang

clang-7: error: linker command failed with exit code 1 for macOS Big Sur

邮差的信 提交于 2020-12-22 19:13:17
问题 Installing R packages that need compiling in macOS is broken since Big Sur. Here is such an example. > install.packages('nlme') There is a binary version available but the source version is later: binary source needs_compilation nlme 3.1-150 3.1-151 TRUE Do you want to install from sources the package which needs compilation? (Yes/no/cancel) Yes installing the source package ‘nlme’ trying URL 'https://cran.rstudio.com/src/contrib/nlme_3.1-151.tar.gz' Content type 'application/x-gzip' length

Can C++17 be used together with CUDA using clang?

给你一囗甜甜゛ 提交于 2020-12-02 05:59:06
问题 As far as using nvcc , one needs to use the corresponding gcc (currently max. 5.4 I believe) in conjunction. This of course somewhat prevents one from using C++17 on the host side. Since C++17 can be compiled using clang 5 and upwards (see here), and one can compile cuda code as well (see here), is it possible to use both C++17 and CUDA at the same time (or can there be problems, e.g. with the CUDA runtime)? 回答1: Yes, as you already guessed the CUDA clang frontend is indeed ahead in C++

Can C++17 be used together with CUDA using clang?

烂漫一生 提交于 2020-12-02 05:58:05
问题 As far as using nvcc , one needs to use the corresponding gcc (currently max. 5.4 I believe) in conjunction. This of course somewhat prevents one from using C++17 on the host side. Since C++17 can be compiled using clang 5 and upwards (see here), and one can compile cuda code as well (see here), is it possible to use both C++17 and CUDA at the same time (or can there be problems, e.g. with the CUDA runtime)? 回答1: Yes, as you already guessed the CUDA clang frontend is indeed ahead in C++

How do I compile C++ to JavaScript in a browser?

别来无恙 提交于 2020-12-01 07:15:10
问题 I'm aware of Emscripten and LLVM, but neither are written in JavaScript intended for a browser. As far as I can tell, the tools exist, but they haven't been put together, but I could very well be missing some key factor that makes it very difficult to compile C++ to JavaScript in a browser. So I'll mention my naive implementation: Compile Emscripten to C, then use Clang to compile it to LLVM, then use Emscripten to compile it to JavaScript. Compile Clang to LLVM, then compile that to

Syscall/sysenter on LLVM

我与影子孤独终老i 提交于 2020-11-30 08:23:12
问题 How do I write the LLVM bitcode required to emit an architecture-specific system call instruction? More specifically, clang supports inline assembly, and clearly supports emitting system calls (otherwise libc and vdso could not be compiled). How does the translation work for this, and how can I tickle it to reproduce this behavior? I understand LLVM itself may not understand the calling interface and register schedule used by various architectures in a sufficiently high-level manner to be

Ambiguous operator overload on clang

徘徊边缘 提交于 2020-11-28 04:43:09
问题 When I try to compile this test program: struct comma_guard { template<class T> const comma_guard& operator,(T&&) const { return *this; } }; struct foo {}; template<class T> T operator,(T x, foo) { return x; } int main() { (comma_guard(), foo()); } I get a compile error on clang: comma_guard.cpp:20:19: error: use of overloaded operator ',' is ambiguous (with operand types 'comma_guard' and 'foo') (comma_guard(), foo()); ~~~~~~~~~~~~~^ ~~~~~ comma_guard.cpp:6:24: note: candidate function [with

Ambiguous operator overload on clang

拜拜、爱过 提交于 2020-11-28 04:42:31
问题 When I try to compile this test program: struct comma_guard { template<class T> const comma_guard& operator,(T&&) const { return *this; } }; struct foo {}; template<class T> T operator,(T x, foo) { return x; } int main() { (comma_guard(), foo()); } I get a compile error on clang: comma_guard.cpp:20:19: error: use of overloaded operator ',' is ambiguous (with operand types 'comma_guard' and 'foo') (comma_guard(), foo()); ~~~~~~~~~~~~~^ ~~~~~ comma_guard.cpp:6:24: note: candidate function [with

Ambiguous operator overload on clang

大兔子大兔子 提交于 2020-11-28 04:39:37
问题 When I try to compile this test program: struct comma_guard { template<class T> const comma_guard& operator,(T&&) const { return *this; } }; struct foo {}; template<class T> T operator,(T x, foo) { return x; } int main() { (comma_guard(), foo()); } I get a compile error on clang: comma_guard.cpp:20:19: error: use of overloaded operator ',' is ambiguous (with operand types 'comma_guard' and 'foo') (comma_guard(), foo()); ~~~~~~~~~~~~~^ ~~~~~ comma_guard.cpp:6:24: note: candidate function [with

RNA velocity | RNA速率

天涯浪子 提交于 2020-11-27 02:27:08
单细胞转录组确实是利器,但我们大多只利用了表达的信息,而从reads到表达之间的信息完全被我们忽略了。 最近nature发了一篇单细胞方法类文章,讲得就是如何利用RNA velocity来做细胞发育路径的推断。 velocyto velocyto -notebooks RNA velocity of single cells 首先需要了解一些基本概念: RNA velocity:the time derivative of the gene expression state—can be directly estimated by distinguishing between unspliced and spliced mRNAs in common single-cell RNA sequencing protocols. a high-dimensional vector that predicts the future state of individual cells on a timescale of hours. 比较抽象,一开始很难理解。 half-life of mRNA:Translation in both prokaryotes and eukaryotes involves three phases: initiation, elongation, and

打造舒适的 VS Code 开发环境

霸气de小男生 提交于 2020-11-26 14:55:37
此文用于记(分)录(享)我的VS Code环境配置(只涉及通用化配置,不包含诸如自定义代码段等定制化配置),主要用于算法/深度学习的日常开发,涉及语言为Python和C++,操作系统为Linux(偶尔用MAC OSX,极少用Windows),开发机器以远程服务器为主, 本地环境为辅。 PS: 这并不是一篇教你如何炫(zhuang)技(B)的文章,使用和配置IDE的前提是你 真正需要它 (适合自己的才是最好的,其实你是VIM党,也可以直接无视本文) 虽说 "工欲善其事必先利其器" ,但我还是建议多将时间花在 钻研技术 或 科研 上。 虽说 "工欲善其事必先利其器" ,但我还是建议多将时间花在 钻研技术 或 科研 上。 虽说 "工欲善其事必先利其器" ,但我还是建议多将时间花在 钻研技术 或 科研 上。 VS Code Customization Basic Settings Extensions Settings Color Theme & File Icon Editor Python Linting & Formatting C++ Linting & Formatting Debugging Remote-SSH SSH Key More Features Basic Settings 首先是比较基础的配置,包括 插件 以及一些 settings配置