Code:
/ 4.0 / 4.0 / DEVDIV_TFS / Dev10 / Releases / RTMRel / ndp / fx / src / Core / System / Linq / Parallel / Scheduling / QueryLifecycle.cs / 1305376 / QueryLifecycle.cs
// ==++== // // Copyright (c) Microsoft Corporation. All rights reserved. // // ==--== // =+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+ // // QueryLifecycle.cs // //[....] // // A convenient place to put things associated with entire queries and their lifecycle events. // // =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=- using System.Diagnostics; using System.Threading; using System.Threading.Tasks; using System.Diagnostics.Contracts; namespace System.Linq.Parallel { internal static class QueryLifecycle { // This method is called once per execution of a logical query. // (It is not called multiple time if repartitionings occur) internal static void LogicalQueryExecutionBegin(int queryID) { //We call NOCTD to inform the debugger that multiple threads will most likely be required to //execute this query. We do not attempt to run the query even if we think we could, for simplicity and consistency. #if !PFX_LEGACY_3_5 Debugger.NotifyOfCrossThreadDependency(); #endif #if !FEATURE_PAL // PAL doesn't support eventing PlinqEtwProvider.Log.ParallelQueryBegin(queryID); #endif } // This method is called once per execution of a logical query. // (It is not called multiple time if repartitionings occur) internal static void LogicalQueryExecutionEnd(int queryID) { #if !FEATURE_PAL // PAL doesn't support eventing PlinqEtwProvider.Log.ParallelQueryEnd(queryID); #endif } } } // File provided for Reference Use Only by Microsoft Corporation (c) 2007. // ==++== // // Copyright (c) Microsoft Corporation. All rights reserved. // // ==--== // =+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+=+ // // QueryLifecycle.cs // //[....] // // A convenient place to put things associated with entire queries and their lifecycle events. // // =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=- using System.Diagnostics; using System.Threading; using System.Threading.Tasks; using System.Diagnostics.Contracts; namespace System.Linq.Parallel { internal static class QueryLifecycle { // This method is called once per execution of a logical query. // (It is not called multiple time if repartitionings occur) internal static void LogicalQueryExecutionBegin(int queryID) { //We call NOCTD to inform the debugger that multiple threads will most likely be required to //execute this query. We do not attempt to run the query even if we think we could, for simplicity and consistency. #if !PFX_LEGACY_3_5 Debugger.NotifyOfCrossThreadDependency(); #endif #if !FEATURE_PAL // PAL doesn't support eventing PlinqEtwProvider.Log.ParallelQueryBegin(queryID); #endif } // This method is called once per execution of a logical query. // (It is not called multiple time if repartitionings occur) internal static void LogicalQueryExecutionEnd(int queryID) { #if !FEATURE_PAL // PAL doesn't support eventing PlinqEtwProvider.Log.ParallelQueryEnd(queryID); #endif } } } // File provided for Reference Use Only by Microsoft Corporation (c) 2007.
Link Menu
This book is available now!
Buy at Amazon US or
Buy at Amazon UK
- MergeFailedEvent.cs
- XmlSchemaObject.cs
- ComponentSerializationService.cs
- storepermissionattribute.cs
- TimelineGroup.cs
- IdentityNotMappedException.cs
- EntityDataSourceState.cs
- SvcFileManager.cs
- Control.cs
- XmlDocumentFragment.cs
- EntityStoreSchemaGenerator.cs
- ProxySimple.cs
- SHA384Managed.cs
- Thread.cs
- ConfigurationManagerInternalFactory.cs
- UpdateTranslator.cs
- CounterSample.cs
- DataStorage.cs
- Calendar.cs
- ThreadSafeList.cs
- ProcessHostConfigUtils.cs
- ContentPresenter.cs
- OdbcCommand.cs
- IgnoreFileBuildProvider.cs
- TabControlAutomationPeer.cs
- TreeViewItemAutomationPeer.cs
- TaskFormBase.cs
- AddInStore.cs
- SmiEventSink_DeferedProcessing.cs
- SerializationObjectManager.cs
- DrawListViewColumnHeaderEventArgs.cs
- ImageCodecInfo.cs
- ListViewDeletedEventArgs.cs
- CollectionEditor.cs
- MediaScriptCommandRoutedEventArgs.cs
- ScaleTransform.cs
- RecognizerInfo.cs
- Console.cs
- BitmapEffect.cs
- TemplatePropertyEntry.cs
- DesignerActionTextItem.cs
- TreeNodeEventArgs.cs
- StateRuntime.cs
- filewebresponse.cs
- MulticastNotSupportedException.cs
- ExtendedPropertyDescriptor.cs
- MobileUITypeEditor.cs
- LinqDataSourceContextEventArgs.cs
- SecUtil.cs
- ActionFrame.cs
- WebPartsPersonalizationAuthorization.cs
- FixedSOMGroup.cs
- UIElement.cs
- DSACryptoServiceProvider.cs
- Speller.cs
- MenuCommandsChangedEventArgs.cs
- EndpointPerformanceCounters.cs
- MethodCallExpression.cs
- ActivityExecutorSurrogate.cs
- CfgParser.cs
- Vector3DConverter.cs
- MethodImplAttribute.cs
- Pens.cs
- WSSecureConversationFeb2005.cs
- PngBitmapDecoder.cs
- ParallelLoopState.cs
- FrameSecurityDescriptor.cs
- DataBinder.cs
- GACIdentityPermission.cs
- WorkflowInstanceRecord.cs
- Switch.cs
- SiteMapNodeItemEventArgs.cs
- _Win32.cs
- PolicyException.cs
- figurelengthconverter.cs
- RankException.cs
- SiteMapDataSource.cs
- FlowDocumentScrollViewerAutomationPeer.cs
- FacetDescription.cs
- PixelFormats.cs
- SetterBaseCollection.cs
- SmiConnection.cs
- ExpressionParser.cs
- InputEventArgs.cs
- ErrorFormatter.cs
- QilList.cs
- Constraint.cs
- SafeCryptContextHandle.cs
- SubstitutionList.cs
- _AutoWebProxyScriptWrapper.cs
- SqlServer2KCompatibilityCheck.cs
- ProxyAttribute.cs
- IResourceProvider.cs
- PrintControllerWithStatusDialog.cs
- NullableLongMinMaxAggregationOperator.cs
- Delegate.cs
- XmlSchemaComplexContent.cs
- DataControlFieldCollection.cs
- BitmapEditor.cs
- ReachPrintTicketSerializer.cs