Click here to Skip to main content
15,394,591 members
Home / Discussions / .NET (Core and Framework)
   

.NET (Core and Framework)

 
GeneralRe: Incorporating values directly (as is/bytewise) into a string Pin
trønderen29-Dec-21 9:28
Membertrønderen29-Dec-21 9:28 
GeneralRe: Incorporating values directly (as is/bytewise) into a string Pin
jsc4231-Jan-22 0:23
professionaljsc4231-Jan-22 0:23 
GeneralRe: Incorporating values directly (as is/bytewise) into a string Pin
primem0ver29-Dec-21 20:36
Memberprimem0ver29-Dec-21 20:36 
GeneralRe: Incorporating values directly (as is/bytewise) into a string Pin
jschell30-Dec-21 8:11
Memberjschell30-Dec-21 8:11 
GeneralRe: Incorporating values directly (as is/bytewise) into a string Pin
jschell30-Dec-21 7:58
Memberjschell30-Dec-21 7:58 
AnswerRe: Incorporating values directly (as is/bytewise) into a string Pin
Gerry Schmitz30-Dec-21 4:50
mveGerry Schmitz30-Dec-21 4:50 
GeneralRe: Incorporating values directly (as is/bytewise) into a string Pin
jschell17-Feb-22 10:48
Memberjschell17-Feb-22 10:48 
AnswerRe: Incorporating values directly (as is/bytewise) into a string Pin
jschell17-Feb-22 11:06
Memberjschell17-Feb-22 11:06 
Efficient is a subjective word. It often is used in the place of fast or sometimes associated with less memory or throughput. Performance is a also often used as well.

None of those mean anything without a context. A medical monitor, a CRC controller and a facebook page are vastly different things and performance means something different for all of them.

In general and almost always the following is what impacts this
1. Business requirements (highest)
2. Architecture
3. Design
4. Implementation (lowest). This also includes adhoc designs that were done without thinking.

It has been proven that developers do not predict impactors on performance when based solely on the implementation level and without profiling. The other levels require human skill.

Optimizations at the first level are capable of having orders of magnitude impacts on the performance of systems. The impact goes done significantly at each level. At the bottom level implementation improvements are unlikely to improve the system by more than 10% unless the a factor comes into play that is actually better addressed by a failure in the levels above it.

primem0ver wrote:
I can think of one possibility using unsafe copying but was wondering if I had any other better (more efficient) options.


The memory mapped variables that you are referring to are "unsafe" because, as proven by decades in C++/C that programmers use them wrong, especially over time. And those failures lead to application crashes. Not just small annoyances but rather problems that make the OS terminate the application immediately. Often in ways that seemingly have nothing to do with where the actual bad code is.

So presumably the need for efficiency is real one. One that has been measured. One that is not actually a failure from one of the other levels.

So if a real need exists and one that has been localized, measured, and designed such that such an optimization can improve something in the enterprise, then as suggested elsewhere use C/C++. Then map away. And if was me I would create a separate executable with just that code. Then when the exe crashes it will not take the rest of the enterprise down.
Questionhow to operate plc from dot net command Pin
Sanket Gaikwad 202128-Dec-21 1:36
MemberSanket Gaikwad 202128-Dec-21 1:36 
AnswerRe: how to operate plc from dot net command Pin
Richard MacCutchan28-Dec-21 2:04
mveRichard MacCutchan28-Dec-21 2:04 
AnswerRe: how to operate plc from dot net command Pin
Gerry Schmitz28-Dec-21 4:10
mveGerry Schmitz28-Dec-21 4:10 
QuestionText Editor color setting Pin
Oscar K.26-Dec-21 20:21
MemberOscar K.26-Dec-21 20:21 
AnswerRe: Text Editor color setting Pin
Gerry Schmitz27-Dec-21 5:19
mveGerry Schmitz27-Dec-21 5:19 
GeneralRe: Text Editor color setting Pin
Oscar K.29-Dec-21 1:07
MemberOscar K.29-Dec-21 1:07 
AnswerRe: Text Editor color setting Pin
trønderen29-Dec-21 1:51
Membertrønderen29-Dec-21 1:51 
PraiseRe: Text Editor color setting Pin
Oscar K.29-Dec-21 23:21
MemberOscar K.29-Dec-21 23:21 
QuestionAny learning materials specifically on porting WPF to MAUI? Pin
greatoceansoftware26-Nov-21 6:02
Membergreatoceansoftware26-Nov-21 6:02 
AnswerRe: Any learning materials specifically on porting WPF to MAUI? Pin
Gerry Schmitz26-Nov-21 8:08
mveGerry Schmitz26-Nov-21 8:08 
GeneralRe: Any learning materials specifically on porting WPF to MAUI? Pin
greatoceansoftware26-Nov-21 9:07
Membergreatoceansoftware26-Nov-21 9:07 
QuestionNew to ASP.NET. Which one should I start with? Pin
Master PC 24-Nov-21 14:56
MemberMaster PC 24-Nov-21 14:56 
AnswerRe: New to ASP.NET. Which one should I start with? Pin
Richard Deeming24-Nov-21 21:29
mveRichard Deeming24-Nov-21 21:29 
QuestionCreating a COM component in .NET 5 Pin
Gaston Verelst19-Nov-21 3:53
MemberGaston Verelst19-Nov-21 3:53 
AnswerRe: Creating a COM component in .NET 5 Pin
Gerry Schmitz19-Nov-21 7:54
mveGerry Schmitz19-Nov-21 7:54 
GeneralRe: Creating a COM component in .NET 5 Pin
Gaston Verelst19-Nov-21 20:29
MemberGaston Verelst19-Nov-21 20:29 
GeneralRe: Creating a COM component in .NET 5 Pin
Gerry Schmitz20-Nov-21 8:18
mveGerry Schmitz20-Nov-21 8:18 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.