mirror of
https://gitlab.com/libeigen/eigen.git
synced 2025-07-20 20:04:26 +08:00
Add synchronize method to all devices.
This commit is contained in:
parent
b7551bff92
commit
551eebc8ca
@ -96,6 +96,10 @@ struct DefaultDevice {
|
||||
#endif
|
||||
}
|
||||
|
||||
EIGEN_DEVICE_FUNC EIGEN_STRONG_INLINE void synchronize() const {
|
||||
// Nothing. Default device operations are synchronous.
|
||||
}
|
||||
|
||||
EIGEN_DEVICE_FUNC EIGEN_STRONG_INLINE int majorDeviceVersion() const {
|
||||
#if !defined(EIGEN_GPU_COMPILE_PHASE)
|
||||
// Running single threaded on the host CPU
|
||||
|
@ -148,6 +148,10 @@ struct ThreadPoolDevice {
|
||||
return l3CacheSize() / num_threads_;
|
||||
}
|
||||
|
||||
EIGEN_DEVICE_FUNC EIGEN_STRONG_INLINE void synchronize() const {
|
||||
// Nothing. Threadpool device operations are synchronous.
|
||||
}
|
||||
|
||||
EIGEN_DEVICE_FUNC EIGEN_STRONG_INLINE int majorDeviceVersion() const {
|
||||
// Should return an enum that encodes the ISA supported by the CPU
|
||||
return 1;
|
||||
|
Loading…
x
Reference in New Issue
Block a user