Commit Graph
59 Commits
Author SHA1 Message Date
Tzanio ca5a4dff6f Various documentation adjustments 2020-06-07 15:56:56 -07:00
Aaron Fisher 523db914fc make style 2020-05-04 16:32:15 -07:00
Aaron Fisher add2e8a3f2 Fixed the remainder of the issues that Mark caught. 2020-04-20 16:51:30 -07:00
Aaron Fisher bb2f464ca6 Merge branch 'master' into dox-update1 2020-04-08 15:15:52 -07:00
Aaron Fisher c3be660074 Merge branch 'master' into dox-update1 2020-04-07 17:25:23 -07:00
William F Godoy 9c379891bf Resolving conflicts with latest master 2020-03-18 09:41:46 -04:00
Tzanio 419bd7c6d7 Some edits in linalg/ 2020-03-09 20:01:11 -07:00
Tzanio 05125e19d5 Removed a space 2020-03-09 15:36:41 -07:00
Tzanio ca55ef0217 The release number for mfem-4.1 is LLNL-CODE-806117 2020-03-02 17:18:46 -08:00
Tzanio 2caa222edf A number of changes to switch the code from LGPL-2.1 to BSD-3:
- Updated LICENSE, README, CHANGELOG and CONTRIBUTING.md
- Removed COPYRIGHT, added NOTICE
- Updated the headers in all source files, makefiles, etc.
2020-02-23 11:16:46 -08:00
Veselin Dobrev 6ab9884606 Remove some temporary debugging code. 2019-11-21 19:37:18 -08:00
Andrew T. Barker eb216b91e3 A few updates to documentation. 2019-07-09 16:02:40 -07:00
Veselin Dobrev 6e457ec497 Fix a few issues related to using the classes SparseMatrix,
HypreParVector, HypreParMatrix, and HypreSmoother with GPU backends.

Add 2 versions of a new method: Vector::MakeRef -- one that takes
a Vector and an offset and another that takes a Vector, an offset
and a new size.

Add some simple debugging tools:
 * Add a new output "trace" stream: mfem::trc. By default, the output
   of mfem::trc goes to std::cout; the new function mfem::OpenTraceFile()
   can be used to redirect the output of mfem::trc to a file called
   'mfem-trace-<pid>' where <pid> is the process id. Note that this
   function can be called from a debugger.
 * In class Vector, add a new method Vector::PrintTrace() that prints a
   Vector to the mfem::trc stream -- this method can be called from a
   debugger, unlike Vector::Print with mfem::trc as argument (at least
   in gdb this did not work).
 * In class Memory<T>, add 2 new methods: PrintFlags() and
   CompareHostAndDevice() which are explicitly instantiated for T=int
   and T=double, so that they can be called inside a debugger for
   these two types.
2019-06-17 18:55:17 -07:00
camierjs bd08fa9592 Merge branch 'memory-dev' of github.com:mfem/mfem into memory-dev 2019-05-24 14:21:12 -07:00
camierjs 283264ade4 {Read,Write,ReadWrite}Access => {Read,Write,ReadWrite}
Add shortcut for Host{Read,Write,ReadWrite}
2019-05-24 14:08:45 -07:00
Tzanio e36d1ea8fd Several change to (hopefully) simplify the interface:
* The parameter of Vector::UseDevice(bool) no longer has a default value. All
  the calls to UseDevice() in operator.cpp bilinearform_ext.cpp gridfunc.?pp and
  linearform.?pp have been replaced with UseDevice(true).

* Added shortcuts for the device flags of the Memory objects inside the Vector
  and Array classes:

    bool Array::UseDevice()
    bool Vector::UseDevice()

* The internal device flag in Memory::FlagMask is now called USE_DEVICE (it was
  previously called EXEC_FLAG). The accessor function for this flag have been
  renamed:

    bool Memory::GetExecFlag()     -> bool Memory::UseDevice()
    void Memory::SetExecFlag(bool) -> void Memory::UseDevice(bool)

* Further renamed:

    Memory::SyncWith         -> Memory::Sync
    Memory::SyncAliasToBase  -> Memory::SyncAlias
    Memory::SyncAliasToBase_ -> Memory::SyncAlias_

* Replaced FIXME with TODO in general/mem_manager.cpp
2019-05-24 14:01:15 -07:00
Tzanio c3999ba78b A few shortcuts for Vector + Memory 2019-05-22 08:16:12 -07:00
Veselin Dobrev e332d2713f Address some FIXME comments. 2019-05-18 16:29:06 -07:00
Veselin Dobrev 40378a046b Introduce a new Memory class for handling host + device allocations
and transfers.

The Memory class is now used by some MFEM classes (like Array and
Vector) which can be used on the Device. Such classes now provide
methods to access the underlying Memory object, e.g. GetMemory.

Updated ex1/ex1p and ex6/ex6p to not need to enable/disable the
Device at specific points -- the Device is now enabled just at the
start. Also, the same examples can now run on Device (e.g. -d cuda)
without the partial assembly option (-pa) -- full assembly will
be still done on CPU but the sparse matrix action and vector
operations will be done using the Device.

Reverted changes in class DenseMatrix related to using the Device.
At this point, DenseMatrix operations are only used for small matrices
and using the Device in this case is not a good option.
2019-05-16 14:53:39 -07:00
camierjs 2020335b50 Renaming + free functions in mfem namespace 2019-04-09 18:17:00 -07:00
camierjs f61b1cc658 Deleted linalg/dvector3.hpp and moved DeviceVector3 into linalg/vector.hpp as Vector3 2019-04-05 10:05:15 -07:00
Will Pazner a5ecb742a0 Revert to using new and delete
Also rename mm::malloc to mm::New and mm::free to mm::Delete.
2019-04-04 13:44:10 -07:00
camierjs 8a4ae9a556 Rework include hierarchy not to present cuda/occa internal headers
Separate dvector3 from dtensor because it is used in coefficient.hpp
2019-04-04 11:45:46 -07:00
Will Pazner 4292eb80bc Replace new and delete with malloc and free in mm
This matches the names of the functions in mm:: and also more closely
matches their use in the rest of mfem.

Also removed the template parameter for mm::free since it is not needed.

It is possible in the future to add equivalents of new and delete to the
mm class (with different names since those are keywords) in case it is
desirable to call the constructor and destructor.
2019-04-03 16:14:13 -07:00
dmed256 2f45b3978c Feedback updates 2019-04-02 13:59:10 -07:00
Tzanio bb7c142ce0 Renamed linalg/device.hpp to linalg/dtensor.hpp.
Some edits in the examples.
2019-03-22 12:15:14 -07:00
camierjs 5ec82bdfd2 Deleted linalg/kernels/vector.?pp 2019-03-06 18:14:33 -08:00
camierjs b05edb2737 Cleanup: Array, Vector 2019-03-06 11:58:36 -08:00
camierjs dd1705d846 Cleanup FEM kernels 2019-02-28 16:00:16 -08:00
camierjs fa4df4b8b3 MFEM_USE_MM, EnsureNodes and MM logic 2018-12-20 16:53:25 -08:00
Tzanio 677b6f8aad Merge branch 'master' into okina
Conflicts:
	fem/bilinearform.hpp
	fem/pbilinearform.hpp
	makefile
2018-12-18 10:07:49 -08:00
Veselin Dobrev b7557d4664 Re-introduce the copy assignment operator in the class
GridFunction, which was incorrectly removed in PR #628 --
this was my mistake.

Add the copy assignment operators in the classes ParGridFunction,
and (Par)LinearForm.

Add copy constructors in the classes QuadratureFunction and
ParGridFunction.

Disallow copy construction of the classes (Par)LinearForm by
declaring their copy constructors as private.

Improve the doxygen documentation in the above mentioned classes.
2018-11-20 19:06:56 -08:00
camierjs 944ef49eeb Melding with master 2018-10-12 15:58:30 -07:00
camierjs 840480b205 Cleanup with master 2018-10-11 10:34:24 -07:00
Jean-Sylvain Camier 7281dbf0fe kernels subdirs & cleanup 2018-10-10 21:00:56 -07:00
camierjs 3b0496d4a5 Ex2 OK, doing SetNodalFESpace before switching to GPU 2018-10-02 18:40:32 -07:00
camierjs 4c072af530 ex1 working, switching to GPU for PCG 2018-09-27 13:07:41 -07:00
camierjs 35dd32e5fc Up to SparseMatrix::AddMult 2018-09-26 17:08:19 -07:00
camierjs 2f6b4c2f07 WIP, *this, When to go to GPU? 2018-09-25 19:25:16 -07:00
camierjs fb25fb6f82 RIP to get Segmentation faults 2018-09-25 16:51:33 -07:00
camierjs e2f7584d7b Init CFG, DBG, MEMCPY & MEMMNG 2018-09-25 16:40:31 -07:00
Veselin Dobrev 522fcfbdc1 Add doxygen documentation for Vector::GetData(). 2018-01-03 01:37:44 -08:00
Veselin Dobrev 42ad503d6e Define a shortcut for std::numeric_limits<double>::infinity() called
mfem::infinity() and replace (almost) all usage of the std version with
the shortcut.

In SparseMatrix::MakeRef, copy the field isSorted from the original
matrix.
2018-01-02 06:36:04 -08:00
Tzanio 1681a52cb6 Adding a comment for #273 2017-11-02 16:19:51 -07:00
Tzanio Kolev bac8f5c330 Merge branch 'master' into xsdk-cpissues-dev 2017-11-02 07:43:37 -07:00
Veselin Dobrev a899cd7b56 In class Vector, add method DistanceSquaredTo that returns the
Euclidean distance squared to another vector.

Also, add a function that performs the same operation, given two
arrays of double values.
2017-10-18 19:18:11 -07:00
Veselin Dobrev 27ffe35369 Merged general/globalcomm.[ch]pp and general/globalostream.[ch]pp into
general/globals.[ch].

Renamed class WrappedOStream to OutStream and use a different
implementation in order to support the case when the OutStream is passed
as a parameter of type std::ostream.

In class MPI_Session, added an MPI_Comm parameter to both constructors,
with a default value of MPI_COMM_WORLD.

Hide the global variable MFEM_COMM_WORLD and allow access (read and
write) with global functions: GetGlobalMPI_Comm() and
SetGlobalMPI_Comm() - in the future, we may want to perform some tasks
when changing the "global" MPI communicator.

In mfem_error(), use GetGlobalMPI_Comm() instead of MPI_COMM_WORLD.

Minor formatting changes and #include reordering.
2017-09-29 15:52:51 -07:00
Aaron Fisher aa040f3e64 Made everything work with the new mfem::out and mfem::err output. 2017-09-27 15:42:37 -07:00
Veselin Dobrev fa9b867764 Proposal for a new implementation of the support for delta
coefficients in linear forms.
2017-08-28 21:01:38 -07:00
Veselin Dobrev f3b433c424 A few adjustments: made all new method/function inline; added 'const'
to some arguments.
2017-03-03 18:17:56 -08:00